Kaynağa Gözat

COMP: Plugins - The LIBRARY_OUTPUT_DIRECTORY is now set at the target level

Within ctkMacroBuildPlugin, instead of updating
CMAKE_LIBRARY_OUTPUT_DIRECTORY, the target property LIBRARY_OUTPUT_DIRECTORY
is set
Jean-Christophe Fillion-Robin 15 yıl önce
ebeveyn
işleme
a8e627c594

+ 4 - 1
CMake/ctkMacroBuildPlugin.cmake

@@ -181,7 +181,10 @@ MACRO(ctkMacroBuildPlugin)
     )
 
   # Apply properties to the library target.
-  SET_TARGET_PROPERTIES(${lib_name}  PROPERTIES COMPILE_FLAGS "-DQT_PLUGIN")
+  SET_TARGET_PROPERTIES(${lib_name} PROPERTIES
+    COMPILE_FLAGS "-DQT_PLUGIN"
+    LIBRARY_OUTPUT_DIRECTORY "${CMAKE_LIBRARY_OUTPUT_DIRECTORY}/plugins"
+    )
 
   # Note: The plugin may be installed in some other location ???
   # Install rules

+ 0 - 2
Plugins/org.commontk.cli/CMakeLists.txt

@@ -20,8 +20,6 @@ SET(PLUGIN_cached_resourcefiles
   servicedescriptor.xml
 )
 
-SET(CMAKE_LIBRARY_OUTPUT_DIRECTORY ${CMAKE_LIBRARY_OUTPUT_DIRECTORY}/Plugins)
-
 ctkMacroGetTargetLibraries(PLUGIN_target_libraries)
 
 ctkMacroBuildPlugin(

+ 0 - 2
Plugins/org.commontk.eventbus/CMakeLists.txt

@@ -17,8 +17,6 @@ SET(PLUGIN_resources
   org_commontk_eventbus.qrc
 )
 
-SET(CMAKE_LIBRARY_OUTPUT_DIRECTORY ${CMAKE_LIBRARY_OUTPUT_DIRECTORY}/Plugins)
-
 ctkMacroGetTargetLibraries(PLUGIN_target_libraries)
 
 ctkMacroBuildPlugin(