Browse files

BUG: Export SlicerBaseLogic and qMRMLWidgetsPythonQt library

git-svn-id: http://svn.slicer.org/Slicer4/trunk@17315 3bd1e089-480b-0410-8dfb-8563597acbee
  • Loading branch information...
1 parent 001d621 commit f7af76fcb9689aef1904faaf71ef7fdb177b9711 @jcfr jcfr committed Jul 3, 2011
Showing with 8 additions and 1 deletion.
  1. +5 −0 Base/Logic/CMakeLists.txt
  2. +3 −1 Libs/qMRMLWidgets/CMakeLists.txt
View
5 Base/Logic/CMakeLists.txt
@@ -150,6 +150,11 @@ if(Slicer_LIBRARY_PROPERTIES)
endif()
# --------------------------------------------------------------------------
+# Export target
+# --------------------------------------------------------------------------
+set_property(GLOBAL APPEND PROPERTY Slicer_TARGETS ${lib_name})
+
+# --------------------------------------------------------------------------
# Install library
# --------------------------------------------------------------------------
install(TARGETS ${lib_name}
View
4 Libs/qMRMLWidgets/CMakeLists.txt
@@ -278,6 +278,7 @@ endif()
# Build library
# --------------------------------------------------------------------------
set(lib_name ${PROJECT_NAME})
+set(targets_to_export ${lib_name})
add_library(${lib_name}
${qMRMLWidgets_SRCS}
@@ -311,6 +312,7 @@ if(qMRMLWidgets_WRAP_PYTHON)
ctkMacroWrapPythonQt("org.slicer.libs" ${lib_name}
KIT_PYTHONQT_SRCS "${qMRMLWidgets_SRCS}" FALSE)
add_library(${lib_name}PythonQt STATIC ${KIT_PYTHONQT_SRCS})
+ list(APPEND targets_to_export ${lib_name}PythonQt)
target_link_libraries(${lib_name}PythonQt ${lib_name})
if(CMAKE_SYSTEM_PROCESSOR STREQUAL "x86_64")
set_target_properties(${lib_name}PythonQt PROPERTIES COMPILE_FLAGS "-fPIC")
@@ -323,7 +325,7 @@ endif()
if(NOT DEFINED ${PROJECT_NAME}_EXPORT_FILE)
set(${PROJECT_NAME}_EXPORT_FILE ${CMAKE_CURRENT_BINARY_DIR}/${PROJECT_NAME}Targets.cmake)
endif()
-export(TARGETS ${lib_name} APPEND FILE ${${PROJECT_NAME}_EXPORT_FILE})
+export(TARGETS ${targets_to_export} APPEND FILE ${${PROJECT_NAME}_EXPORT_FILE})
# --------------------------------------------------------------------------
# Install library

0 comments on commit f7af76f

Please sign in to comment.