From 269aa4c7df03e1e581c01866c91bcfa5524d6334 Mon Sep 17 00:00:00 2001 From: Robert Tari Date: Tue, 27 Aug 2024 14:43:59 +0200 Subject: Rewrite using C/CMake/Gtk4 and add some features/tweaks --- data/CMakeLists.txt | 31 +++++++++++++++++++++++++++++++ 1 file changed, 31 insertions(+) create mode 100644 data/CMakeLists.txt (limited to 'data/CMakeLists.txt') diff --git a/data/CMakeLists.txt b/data/CMakeLists.txt new file mode 100644 index 0000000..507df29 --- /dev/null +++ b/data/CMakeLists.txt @@ -0,0 +1,31 @@ +# ayatana-settings.8 + +install (FILES "${CMAKE_CURRENT_SOURCE_DIR}/${CMAKE_PROJECT_NAME}.8" DESTINATION "${CMAKE_INSTALL_FULL_MANDIR}/man8") + +# ayatana-settings.desktop + +find_package (Intltool REQUIRED) +configure_file ("${CMAKE_CURRENT_SOURCE_DIR}/${CMAKE_PROJECT_NAME}.desktop.in" "${CMAKE_CURRENT_BINARY_DIR}/${CMAKE_PROJECT_NAME}.desktop.intl" @ONLY) +intltool_merge_translations ("${CMAKE_PROJECT_NAME}.desktop.intl" "${CMAKE_PROJECT_NAME}.desktop" ALL UTF8) +install (FILES "${CMAKE_CURRENT_BINARY_DIR}/${CMAKE_PROJECT_NAME}.desktop" DESTINATION "${CMAKE_INSTALL_FULL_DATADIR}/applications") + +# icons/ContrastHigh/scalable/apps/ayatana-settings.svg +# icons/hicolor/scalable/apps/ayatana-settings.svg + +install (DIRECTORY "${CMAKE_CURRENT_SOURCE_DIR}/icons" DESTINATION "${CMAKE_INSTALL_FULL_DATADIR}") + +# ayatana-settings-gresource.c + +find_program (GLIB_COMPILE_RESOURCES NAMES glib-compile-resources REQUIRED) + +add_custom_command ( + OUTPUT "${CMAKE_PROJECT_NAME}-gresource.c" + WORKING_DIRECTORY "${CMAKE_CURRENT_SOURCE_DIR}" + COMMAND "${GLIB_COMPILE_RESOURCES}" + ARGS --target "${CMAKE_CURRENT_BINARY_DIR}/${CMAKE_PROJECT_NAME}-gresource.c" --generate-source "${CMAKE_PROJECT_NAME}.xml" + VERBATIM + MAIN_DEPENDENCY "${CMAKE_PROJECT_NAME}.xml" + DEPENDS "${CMAKE_PROJECT_NAME}.ui" +) + +add_custom_target ("data" DEPENDS "${CMAKE_CURRENT_BINARY_DIR}/${CMAKE_PROJECT_NAME}-gresource.c") -- cgit v1.2.3