summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorModestas Vainius <modax@debian.org>2011-05-25 14:17:07 +0300
committerModestas Vainius <modax@debian.org>2011-05-25 14:17:07 +0300
commitaa9b5d5f8c9999f3a8b6838e5360899f36dc4bee (patch)
tree15b377cb55378adad460efa4c66bf1ff2022cb3c
parentda731036063b76331e1bf4f8da43cc37e4ea7232 (diff)
downloadpkg-kde-tools-aa9b5d5f8c9999f3a8b6838e5360899f36dc4bee.tar.gz
DLRestrictionsConfig.cmake: handle MODULE_LIBRARY like SHARED_LIBRARY.
Modules are shared objects as well.
-rw-r--r--dlrestrictions/DLRestrictionsConfig.cmake4
1 files changed, 2 insertions, 2 deletions
diff --git a/dlrestrictions/DLRestrictionsConfig.cmake b/dlrestrictions/DLRestrictionsConfig.cmake
index 4fb643b..87bd2f2 100644
--- a/dlrestrictions/DLRestrictionsConfig.cmake
+++ b/dlrestrictions/DLRestrictionsConfig.cmake
@@ -31,9 +31,9 @@ function(DLRESTRICTIONS_PROCESS_TARGETS)
configure_file("${DLRESTRICTIONS_SYMBOL_SOURCE_FILE}" "${dlr_target_file}" @ONLY)
add_library(${dlr_target} STATIC "${dlr_target_file}")
get_property(dlr_target_type TARGET ${target} PROPERTY TYPE)
- if (${dlr_target_type} STREQUAL "SHARED_LIBRARY")
+ if (${dlr_target_type} MATCHES "^(SHARED|MODULE)_LIBRARY$")
set_property(TARGET ${dlr_target} PROPERTY COMPILE_FLAGS "${CMAKE_SHARED_LIBRARY_C_FLAGS}" APPEND)
- endif (${dlr_target_type} STREQUAL "SHARED_LIBRARY")
+ endif (${dlr_target_type} MATCHES "^(SHARED|MODULE)_LIBRARY$")
set_property(TARGET ${dlr_target} PROPERTY EchoString "Adding DLRestrictions (=${dlr_expression}) for ${target}")
# FIXME: not portable
target_link_libraries(${target} "-Wl,--whole-archive" ${dlr_target} "-Wl,--no-whole-archive")