From 1cb912e4f90473f78d2f0f10ab5c9b2c5bd36440 Mon Sep 17 00:00:00 2001 From: Maksym Mamontov Date: Wed, 28 Dec 2022 16:32:34 +0200 Subject: [PATCH 1/1] Fix build on Darwin. --- projects/stargazer/plugins/CMakeLists.txt | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/projects/stargazer/plugins/CMakeLists.txt b/projects/stargazer/plugins/CMakeLists.txt index 8adb6c5f..fc378ba6 100644 --- a/projects/stargazer/plugins/CMakeLists.txt +++ b/projects/stargazer/plugins/CMakeLists.txt @@ -155,6 +155,9 @@ if ( BUILD_MOD_RPCCONFIG ) configuration/rpcconfig/messages_methods.cpp ) target_link_libraries ( mod_conf_rpc scriptexecuter logger common ${XMLRPC_LIBRARIES} ) set_target_properties ( mod_conf_rpc PROPERTIES PREFIX "" ) + if ( ${CMAKE_SYSTEM_NAME} STREQUAL "Darwin" ) + set_target_properties ( mod_conf_rpc PROPERTIES LINK_FLAGS "-undefined dynamic_lookup" ) + endif ( ${CMAKE_SYSTEM_NAME} STREQUAL "Darwin" ) if ( CLANG_TIDY_EXE ) set_target_properties ( mod_conf_rpc PROPERTIES CXX_CLANG_TIDY "${DO_CLANG_TIDY}" ) @@ -272,6 +275,9 @@ if ( BUILD_MOD_STORE_POSTGRESQL ) store/postgresql/postgresql_store_utils.cpp ) target_link_libraries ( mod_store_postgresql crypto logger common ${PostgreSQL_LIBRARIES} ) set_target_properties ( mod_store_postgresql PROPERTIES PREFIX "" ) + if ( ${CMAKE_SYSTEM_NAME} STREQUAL "Darwin" ) + set_target_properties ( mod_store_postgresql PROPERTIES LINK_FLAGS "-undefined dynamic_lookup" ) + endif ( ${CMAKE_SYSTEM_NAME} STREQUAL "Darwin" ) if ( CLANG_TIDY_EXE ) set_target_properties ( mod_store_postgresql PROPERTIES CXX_CLANG_TIDY "${DO_CLANG_TIDY}" ) -- 2.44.2