summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJiwoong Im <jiwoong.im@samsung.com>2016-11-18 10:43:49 +0900
committerJiwoong Im <jiwoong.im@samsung.com>2016-11-18 10:43:49 +0900
commit488a44820e019dda774d4339bc3e5757bd97f502 (patch)
tree96dc5f4058981c6b0b17bdf737c5b687507430f1
parent1e4b42f70ebca5ce16c7b1a4283d63634b388d5c (diff)
downloadlibeventsystem-488a44820e019dda774d4339bc3e5757bd97f502.tar.gz
libeventsystem-488a44820e019dda774d4339bc3e5757bd97f502.tar.bz2
libeventsystem-488a44820e019dda774d4339bc3e5757bd97f502.zip
To make extendible for adding source & header files. Change-Id: Ibb73e9f65212fc384393cc4a1fee5a743e26946d Signed-off-by: Jiwoong Im <jiwoong.im@samsung.com>
-rw-r--r--CMakeLists.txt11
1 files changed, 6 insertions, 5 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 08cad00..e44e3be 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -1,6 +1,7 @@
CMAKE_MINIMUM_REQUIRED(VERSION 2.6)
PROJECT(eventsystem C)
+AUX_SOURCE_DIRECTORY(src/ SRCS)
SET(VERSION 0.0.1)
SET(VERSION_MAJOR 0)
@@ -35,9 +36,7 @@ SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} ${EXTRA_CFLAGS}")
SET(CMAKE_EXE_LINKER_FLAGS "-Wl,--as-needed")
## build eventsystem library
-add_library(eventsystem SHARED
- src/eventsystem.c
- )
+add_library(eventsystem SHARED ${SRCS})
#TARGET_LINK_LIBRARIES(eventsystem "-ldl")
TARGET_LINK_LIBRARIES(eventsystem ${libpkgs_LDFLAGS})
@@ -50,5 +49,7 @@ configure_file(eventsystem.manifest.in eventsystem.manifest @ONLY)
INSTALL(TARGETS eventsystem DESTINATION ${LIB_INSTALL_DIR} COMPONENT RuntimeLibraries)
INSTALL(FILES ${CMAKE_CURRENT_BINARY_DIR}/eventsystem.pc DESTINATION ${LIB_INSTALL_DIR}/pkgconfig)
-INSTALL(FILES ${CMAKE_CURRENT_SOURCE_DIR}/include/eventsystem.h DESTINATION include)
-INSTALL(FILES ${CMAKE_CURRENT_SOURCE_DIR}/include/eventsystem_internal.h DESTINATION include)
+INSTALL(DIRECTORY ${CMAKE_SOURCE_DIR}/include/ DESTINATION include/
+ FILES_MATCHING
+ PATTERN "*.h"
+ )