From 83d5ba42f8a98fc0df177efef4333f74a0481f61 Mon Sep 17 00:00:00 2001 From: pants Date: Mon, 21 Sep 2026 14:18:06 -0700 Subject: init --- plugins/wayfire/CMakeLists.txt | 66 ++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 66 insertions(+) create mode 100644 plugins/wayfire/CMakeLists.txt (limited to 'plugins/wayfire/CMakeLists.txt') diff --git a/plugins/wayfire/CMakeLists.txt b/plugins/wayfire/CMakeLists.txt new file mode 100644 index 0000000..8044b8f --- /dev/null +++ b/plugins/wayfire/CMakeLists.txt @@ -0,0 +1,66 @@ +# Display images inside a terminal +# Copyright (C) 2023 JustKidding +# +# This program is free software: you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation, either version 3 of the License, or +# (at your option) any later version. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with this program. If not, see . + +cmake_minimum_required(VERSION 3.18) + +set(CMAKE_C_STANDARD 17) +set(CMAKE_C_STANDARD_REQUIRED ON) +set(CMAKE_C_EXTENSIONS OFF) +set(CMAKE_CXX_STANDARD 20) +set(CMAKE_CXX_STANDARD_REQUIRED ON) +set(CMAKE_CXX_EXTENSIONS OFF) +set(CMAKE_EXPORT_COMPILE_COMMANDS ON) +set(CMAKE_BUILD_TYPE Debug CACHE STRING "Build type.") + +cmake_policy(SET CMP0065 NEW) +set(CMAKE_ENABLE_EXPORTS ON) + +project(wayfire-ueberzugpp LANGUAGES CXX C VERSION 0.0.1) +add_library(ueberzugpp SHARED) + +list(APPEND PLUGIN_SOURCES "ueberzugpp.cpp") + +find_package(PkgConfig REQUIRED) + +find_package(ECM REQUIRED NO_MODULE) +list(APPEND CMAKE_MODULE_PATH ${ECM_MODULE_PATH}) +find_package(WaylandProtocols REQUIRED) +find_package(WaylandScanner REQUIRED) + +ecm_add_wayland_server_protocol(PLUGIN_SOURCES + PROTOCOL "${WaylandProtocols_DATADIR}/stable/xdg-shell/xdg-shell.xml" + BASENAME "xdg-shell") +file(CREATE_LINK + "wayland-xdg-shell-server-protocol.h" + "${PROJECT_BINARY_DIR}/xdg-shell-protocol.h" SYMBOLIC) + +pkg_check_modules(WAYFIRE REQUIRED IMPORTED_TARGET wayfire) +pkg_check_modules(WLROOTS REQUIRED IMPORTED_TARGET wlroots) +pkg_check_modules(WFCONFIG REQUIRED IMPORTED_TARGET wf-config) + +add_compile_definitions(WLR_USE_UNSTABLE WAYFIRE_PLUGIN) +target_compile_options(ueberzugpp PRIVATE + $<$: + -Wall -Wextra -Wpedantic -Werror + > +) + +target_include_directories(ueberzugpp PRIVATE "${PROJECT_BINARY_DIR}") +target_sources(ueberzugpp PRIVATE ${PLUGIN_SOURCES}) +target_link_libraries(ueberzugpp + PkgConfig::WAYFIRE + PkgConfig::WLROOTS + PkgConfig::WFCONFIG) -- cgit v1.2.3