From 41417fbc32cedc013d054ea963b01cbafe74f631 Mon Sep 17 00:00:00 2001 From: Timo Lotterbach Date: Fri, 4 Jan 2013 04:01:17 -0800 Subject: [PATCH] CMake: using LIBRARY_BUILDMODE for libraries responding to WITH_STATIC_LIBRARIES Signed-off-by: Timo Lotterbach --- LayerManagerCommands/CMakeLists.txt | 6 +----- LayerManagerPlugins/IpcModules/IpcModuleLoader/CMakeLists.txt | 6 +----- 2 files changed, 2 insertions(+), 10 deletions(-) diff --git a/LayerManagerCommands/CMakeLists.txt b/LayerManagerCommands/CMakeLists.txt index 3925a4a..746a579 100644 --- a/LayerManagerCommands/CMakeLists.txt +++ b/LayerManagerCommands/CMakeLists.txt @@ -32,11 +32,7 @@ include_directories( file(GLOB LM_SOURCES src/*.cpp) file(GLOB LM_INCLUDES include/*.h) -if (WITH_STATIC_LIBRARIES) - add_library(${PROJECT_NAME} STATIC ${LM_SOURCES}) -else (WITH_STATIC_LIBRARIES) - add_library(${PROJECT_NAME} SHARED ${LM_SOURCES}) -endif (WITH_STATIC_LIBRARIES) +add_library(${PROJECT_NAME} ${LIBRARY_BUILDMODE} ${LM_SOURCES}) set(LIBS ${LIBS} LayerManagerUtils LayerManagerBase) target_link_libraries(${PROJECT_NAME} ${LIBS}) diff --git a/LayerManagerPlugins/IpcModules/IpcModuleLoader/CMakeLists.txt b/LayerManagerPlugins/IpcModules/IpcModuleLoader/CMakeLists.txt index 0798e18..eb43a75 100644 --- a/LayerManagerPlugins/IpcModules/IpcModuleLoader/CMakeLists.txt +++ b/LayerManagerPlugins/IpcModules/IpcModuleLoader/CMakeLists.txt @@ -28,11 +28,7 @@ include_directories( "${CMAKE_SOURCE_DIR}/LayerManagerPlugins/IpcModules/IpcModuleLoader/include" ) -if(WITH_STATIC_LIBRARIES) - add_library(IpcModuleLoader STATIC src/IpcModuleLoader.c) -else(WITH_STATIC_LIBRARIES) - add_library(IpcModuleLoader SHARED src/IpcModuleLoader.c) -endif(WITH_STATIC_LIBRARIES) +add_library(IpcModuleLoader ${LIBRARY_BUILDMODE} src/IpcModuleLoader.c) set(LIBS dl -- 2.7.4