From d60488f73efc2648a2c214259ff30fc296c8e3ef Mon Sep 17 00:00:00 2001 From: Steven Oliver Date: Mon, 27 Aug 2012 17:27:15 -0400 Subject: [PATCH] Have only FreeBSD require dynamic linking (FS#743) Signed-off-by: Steven Oliver Signed-off-by: Uli Schlachter --- CMakeLists.txt | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index aa09f48e..3fcf6b9e 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -92,9 +92,12 @@ endif() add_executable(${PROJECT_AWE_NAME} ${AWE_SRCS}) -set_target_properties(${PROJECT_AWE_NAME} - PROPERTIES - LINK_FLAGS -export-dynamic) +# FreeBSD requires dynamic linking +if(${CMAKE_SYSTEM_NAME} MATCHES "FreeBSD") + set_target_properties(${PROJECT_AWE_NAME} + PROPERTIES + LINK_FLAGS -export-dynamic) +endif() target_link_libraries(${PROJECT_AWE_NAME} ${AWESOME_COMMON_REQUIRED_LDFLAGS}