From d325dab035b6d627cc1112715e8fad4753faa636 Mon Sep 17 00:00:00 2001 From: Alejandro Sior Date: Wed, 17 Feb 2021 16:59:30 +0100 Subject: [PATCH] added conditionals to build on FreeBSD --- CMakeLists.txt | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index 773d4b3..cbc5a55 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -83,6 +83,11 @@ if (${CMAKE_SYSTEM_NAME} MATCHES "OpenBSD") add_custom_target(do_always ALL cp \"$/libsdrpp_core.so\" \"$\") endif () +if (${CMAKE_SYSTEM_NAME} MATCHES "FreeBSD") + target_link_libraries(sdrpp PUBLIC pthread) + add_custom_target(do_always ALL cp \"$/libsdrpp_core.so\" \"$\") +endif () + if (${CMAKE_SYSTEM_NAME} MATCHES "Linux") add_custom_target(do_always ALL cp \"$/libsdrpp_core.so\" \"$\") endif () @@ -104,4 +109,4 @@ install(FILES ${CMAKE_CURRENT_BINARY_DIR}/sdrpp.desktop DESTINATION /usr/share/a # Create uninstall target configure_file(${CMAKE_SOURCE_DIR}/cmake_uninstall.cmake ${CMAKE_CURRENT_BINARY_DIR}/cmake_uninstall.cmake @ONLY) -add_custom_target(uninstall ${CMAKE_COMMAND} -P ${CMAKE_CURRENT_BINARY_DIR}/cmake_uninstall.cmake) \ No newline at end of file +add_custom_target(uninstall ${CMAKE_COMMAND} -P ${CMAKE_CURRENT_BINARY_DIR}/cmake_uninstall.cmake)