From: Daniel Arndt Date: Tue, 21 Mar 2023 17:16:43 +0000 (-0400) Subject: Fix configuring with static libraries X-Git-Tag: v9.5.0-rc1~443^2 X-Git-Url: https://gitweb.dealii.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=fd6d8d6a6e8b07828a95a0c5a80f9341165da354;p=dealii.git Fix configuring with static libraries --- diff --git a/source/CMakeLists.txt b/source/CMakeLists.txt index 25214e6817..ca59fe2abe 100644 --- a/source/CMakeLists.txt +++ b/source/CMakeLists.txt @@ -83,7 +83,7 @@ foreach(build ${DEAL_II_BUILD_TYPES}) # set(_object_files "") - if(CMAKE_SYSTEM_NAME MATCHES "Windows") + if(NOT BUILD_SHARED_LIBS) get_property(_object_targets GLOBAL PROPERTY DEAL_II_OBJECT_TARGETS_${build}) foreach(_target ${_object_targets}) list(APPEND _object_files "$") @@ -99,7 +99,7 @@ foreach(build ${DEAL_II_BUILD_TYPES}) # populate_target_properties(${DEAL_II_NAMESPACE}_${build_lowercase} ${build}) - if(NOT CMAKE_SYSTEM_NAME MATCHES "Windows") + if(BUILD_SHARED_LIBS) # # Add all object targets as private link targets #