From e2dad5f30ca4d8502558e0560d2059a51aae4c4c Mon Sep 17 00:00:00 2001 From: Felix Morgner Date: Mon, 19 Aug 2024 09:11:09 +0200 Subject: core: add settings accessor --- core/CMakeLists.txt | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) (limited to 'core/CMakeLists.txt') diff --git a/core/CMakeLists.txt b/core/CMakeLists.txt index 9b6390c..5ec88e4 100644 --- a/core/CMakeLists.txt +++ b/core/CMakeLists.txt @@ -4,6 +4,7 @@ add_library("core" "src/disposition.cpp" "src/init.cpp" "src/participant.cpp" + "src/settings.cpp" "src/turn_order.cpp" ) @@ -16,6 +17,12 @@ target_compile_options("core" PUBLIC "$<$:-pedantic-errors>" ) +if(NOT TURNS_USE_INSTALLED_SCHEMA_FILES) + target_compile_definitions("core" PUBLIC + "TURNS_SETTINGS_SCHEMA_DIR=\"${CMAKE_CURRENT_BINARY_DIR}\"" + ) +endif() + target_include_directories("core" PUBLIC "include" ) @@ -26,8 +33,17 @@ target_link_libraries("core" PUBLIC "nlohmann_json::nlohmann_json" ) +target_add_glib_schemas("core" + SCHEMA_DIR "schemas" +) + enable_coverage("core") +install(FILES + "schemas/ch.arknet.Turns.gschema.xml" + DESTINATION "${CMAKE_INSTALL_DATAROOTDIR}/glib-2.0/schemas" +) + # Tests add_executable("core-tests" -- cgit v1.2.3