summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlexis Hildebrandt <afh@surryhill.net>2024-01-17 00:14:29 +0100
committerJohn Wiegley <johnw@newartisans.com>2024-07-08 10:12:53 -0700
commit92db49d2e0d649c31b93be1e0cd0b5cde5ce57d8 (patch)
treeae743568e1e5ba4dbf57fe257a1df66c4f7b33d1
parentb3d65517121ac67637dfe2bd81e15f84fb0593aa (diff)
downloadfork-ledger-92db49d2e0d649c31b93be1e0cd0b5cde5ce57d8.tar.gz
fork-ledger-92db49d2e0d649c31b93be1e0cd0b5cde5ce57d8.tar.bz2
fork-ledger-92db49d2e0d649c31b93be1e0cd0b5cde5ce57d8.zip
cmake: Clean up add_ledger_library_dependencies macro
-rw-r--r--CMakeLists.txt16
1 files changed, 7 insertions, 9 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 63dacc12..aa8594e4 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -273,8 +273,10 @@ endif (NOT HAVE_EDIT)
########################################################################
macro(add_ledger_library_dependencies _target)
- target_link_libraries(${_target} ${MPFR_LIB})
+ target_link_libraries(${_target} ${Boost_LIBRARIES})
target_link_libraries(${_target} ${GMP_LIB})
+ target_link_libraries(${_target} ${MPFR_LIB})
+ target_link_libraries(${_target} ${PROFILE_LIBS})
if (HAVE_EDIT)
target_link_libraries(${_target} ${EDIT_LIB})
endif()
@@ -287,22 +289,18 @@ macro(add_ledger_library_dependencies _target)
if (HAVE_GPGME)
target_link_libraries(${_target} Gpgmepp)
endif()
+ if (HAVE_BOOST_REGEX_UNICODE)
+ target_link_libraries(${_target} ${ICU_LIBRARIES})
+ endif()
if (HAVE_BOOST_PYTHON)
if (CMAKE_SYSTEM_NAME STREQUAL Darwin)
# Don't link directly to a Python framework on macOS, to avoid segfaults
# when the module is imported from a different interpreter
- target_link_libraries(${_target} ${Boost_LIBRARIES})
set_target_properties(${_target} PROPERTIES LINK_FLAGS "-undefined dynamic_lookup")
else()
- target_link_libraries(${_target} ${Boost_LIBRARIES} ${Python_LIBRARIES})
+ target_link_libraries(${_target} ${Python_LIBRARIES})
endif()
- else()
- target_link_libraries(${_target} ${Boost_LIBRARIES})
endif()
- if (HAVE_BOOST_REGEX_UNICODE)
- target_link_libraries(${_target} ${ICU_LIBRARIES})
- endif()
- target_link_libraries(${_target} ${PROFILE_LIBS})
endmacro(add_ledger_library_dependencies _target)
########################################################################