diff options
Diffstat (limited to 'source')
| -rw-r--r-- | source/lib/CMakeLists.txt | 4 | ||||
| -rw-r--r-- | source/lib/control/CMakeLists.txt | 10 | ||||
| -rw-r--r-- | source/lib/meta/CMakeLists.txt | 8 | ||||
| -rw-r--r-- | source/lib/proto/CMakeLists.txt | 10 | ||||
| -rw-r--r-- | source/lib/std_ext/CMakeLists.txt | 8 | ||||
| -rw-r--r-- | source/lib/system/CMakeLists.txt | 10 |
6 files changed, 32 insertions, 18 deletions
diff --git a/source/lib/CMakeLists.txt b/source/lib/CMakeLists.txt index e2bb4b5..b9cafe7 100644 --- a/source/lib/CMakeLists.txt +++ b/source/lib/CMakeLists.txt @@ -1,3 +1,7 @@ +if(WANDA_APPLICATIONS_ONLY) + set(WANDA_LIBRARY_TYPE OBJECT) +endif() + add_subdirectory("control") add_subdirectory("meta") add_subdirectory("proto") diff --git a/source/lib/control/CMakeLists.txt b/source/lib/control/CMakeLists.txt index 2fce909..9e5a33d 100644 --- a/source/lib/control/CMakeLists.txt +++ b/source/lib/control/CMakeLists.txt @@ -6,7 +6,7 @@ file(GLOB_RECURSE LIB_SOURCES RELATIVE "${CMAKE_CURRENT_SOURCE_DIR}" CONFIGURE_D find_package("Boost" REQUIRED COMPONENTS "headers") find_package("spdlog" REQUIRED) -add_library("wanda-${LIB_NAME}" +add_library("wanda-${LIB_NAME}" ${WANDA_LIBRARY_TYPE} ${LIB_SOURCES} ) @@ -37,8 +37,10 @@ target_link_libraries("wanda-${LIB_NAME}" PUBLIC "spdlog::spdlog_header_only" ) -install(TARGETS "wanda-${LIB_NAME}" - FILE_SET HEADERS -) +if(NOT WANDA_APPLICATIONS_ONLY) + install(TARGETS "wanda-${LIB_NAME}" + FILE_SET HEADERS + ) +endif() add_library("wanda::${LIB_NAME}" ALIAS "wanda-${LIB_NAME}") diff --git a/source/lib/meta/CMakeLists.txt b/source/lib/meta/CMakeLists.txt index e6e3372..d21d45c 100644 --- a/source/lib/meta/CMakeLists.txt +++ b/source/lib/meta/CMakeLists.txt @@ -22,8 +22,10 @@ target_compile_features("wanda-${LIB_NAME}" INTERFACE "cxx_std_20" ) -install(TARGETS "wanda-${LIB_NAME}" - FILE_SET HEADERS -) +if(NOT WANDA_APPLICATIONS_ONLY) + install(TARGETS "wanda-${LIB_NAME}" + FILE_SET HEADERS + ) +endif() add_library("wanda::${LIB_NAME}" ALIAS "wanda-${LIB_NAME}") diff --git a/source/lib/proto/CMakeLists.txt b/source/lib/proto/CMakeLists.txt index cc218ba..a99c364 100644 --- a/source/lib/proto/CMakeLists.txt +++ b/source/lib/proto/CMakeLists.txt @@ -5,7 +5,7 @@ file(GLOB_RECURSE LIB_SOURCES RELATIVE "${CMAKE_CURRENT_SOURCE_DIR}" CONFIGURE_D find_package("spdlog") -add_library("wanda-${LIB_NAME}" +add_library("wanda-${LIB_NAME}" ${WANDA_LIBRARY_TYPE} ${LIB_SOURCES} ) @@ -31,8 +31,10 @@ target_link_libraries("wanda-${LIB_NAME}" PUBLIC "spdlog::spdlog_header_only" ) -install(TARGETS "wanda-${LIB_NAME}" - FILE_SET HEADERS -) +if(NOT WANDA_APPLICATIONS_ONLY) + install(TARGETS "wanda-${LIB_NAME}" + FILE_SET HEADERS + ) +endif() add_library("wanda::${LIB_NAME}" ALIAS "wanda-${LIB_NAME}") diff --git a/source/lib/std_ext/CMakeLists.txt b/source/lib/std_ext/CMakeLists.txt index e6e3372..d21d45c 100644 --- a/source/lib/std_ext/CMakeLists.txt +++ b/source/lib/std_ext/CMakeLists.txt @@ -22,8 +22,10 @@ target_compile_features("wanda-${LIB_NAME}" INTERFACE "cxx_std_20" ) -install(TARGETS "wanda-${LIB_NAME}" - FILE_SET HEADERS -) +if(NOT WANDA_APPLICATIONS_ONLY) + install(TARGETS "wanda-${LIB_NAME}" + FILE_SET HEADERS + ) +endif() add_library("wanda::${LIB_NAME}" ALIAS "wanda-${LIB_NAME}") diff --git a/source/lib/system/CMakeLists.txt b/source/lib/system/CMakeLists.txt index 6b7ce7c..59d0b50 100644 --- a/source/lib/system/CMakeLists.txt +++ b/source/lib/system/CMakeLists.txt @@ -24,7 +24,7 @@ pkg_check_modules("libmagic" "libmagic" ) -add_library("wanda-${LIB_NAME}" +add_library("wanda-${LIB_NAME}" ${WANDA_LIBRARY_TYPE} ${LIB_SOURCES} ) @@ -59,8 +59,10 @@ target_link_libraries("wanda-${LIB_NAME}" PUBLIC "PkgConfig::GIO" ) -install(TARGETS "wanda-${LIB_NAME}" - FILE_SET HEADERS -) +if(NOT WANDA_APPLICATIONS_ONLY) + install(TARGETS "wanda-${LIB_NAME}" + FILE_SET HEADERS + ) +endif() add_library("wanda::${LIB_NAME}" ALIAS "wanda-${LIB_NAME}") |
