summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChristian Mollekopf <mollekopf@kolabsys.com>2012-10-17 16:02:58 (GMT)
committerChristian Mollekopf <mollekopf@kolabsys.com>2012-10-17 16:02:58 (GMT)
commit5c31e4a8a9f40aa50810ab3169247734b8acd5d1 (patch)
treea23b052b68fb0da0c1883648ab3499bb0528d089
parent5751be941b444a719eec44fe501ab5db0526a009 (diff)
downloadkolab-utils-5c31e4a8a9f40aa50810ab3169247734b8acd5d1.tar.gz
Make the library shared and fix the symbol visibility.
-rw-r--r--lib/CMakeLists.txt5
-rw-r--r--migrationutility/CMakeLists.txt2
-rw-r--r--migrationutility/tests/CMakeLists.txt3
3 files changed, 6 insertions, 4 deletions
diff --git a/lib/CMakeLists.txt b/lib/CMakeLists.txt
index 9763171..60bffe9 100644
--- a/lib/CMakeLists.txt
+++ b/lib/CMakeLists.txt
@@ -1,6 +1,9 @@
include_directories(./)
+# Otherwise we'd have to export all classes in the library
+set( CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -fvisibility=default" )
+
add_subdirectory(jobs)
QT4_WRAP_CPP(JOB_MOC
${CMAKE_CURRENT_SOURCE_DIR}/jobs/findkolabfoldersjob.h
@@ -22,5 +25,5 @@ set(SRCS ${JOBS_SRCS}
${MOC}
)
-add_library(kolabutils ${SRCS})
+add_library(kolabutils SHARED ${SRCS})
target_link_libraries(kolabutils ${COMMON_DEPENDENCIES})
diff --git a/migrationutility/CMakeLists.txt b/migrationutility/CMakeLists.txt
index c4fdf4e..ccc5737 100644
--- a/migrationutility/CMakeLists.txt
+++ b/migrationutility/CMakeLists.txt
@@ -38,4 +38,4 @@ install(TARGETS kolab-migration
ARCHIVE DESTINATION ${LIB_INSTALL_DIR}
)
-# add_subdirectory(tests) \ No newline at end of file
+# add_subdirectory(tests)
diff --git a/migrationutility/tests/CMakeLists.txt b/migrationutility/tests/CMakeLists.txt
index 6c029b1..257dd90 100644
--- a/migrationutility/tests/CMakeLists.txt
+++ b/migrationutility/tests/CMakeLists.txt
@@ -20,8 +20,7 @@ qt4_generate_moc(
add_executable(migrationtest ${MIGRATION_SRCS} ${MIGRATION_MOC} migrationtest.cpp)
# set_target_properties(migrationtest PROPERTIES AUTOMOC TRUE)
-
-target_link_libraries(migrationtest ${COMMON_DEPENDENCIES} ${QT_QTTEST_LIBRARY})
+target_link_libraries(migrationtest ${COMMON_DEPENDENCIES} ${QT_QTTEST_LIBRARY} kolabutils)
qt4_generate_moc(
${CMAKE_CURRENT_SOURCE_DIR}/migrationscenariotest.cpp