1 # Copyright (c) 2013 Samsung Electronics Co., Ltd All Rights Reserved
3 # Licensed under the Flora License, Version 1.1 (the "License");
4 # you may not use this file except in compliance with the License.
5 # You may obtain a copy of the License at
7 # http://floralicense.org/license/
9 # Unless required by applicable law or agreed to in writing, software
10 # distributed under the License is distributed on an "AS IS" BASIS,
11 # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12 # See the License for the specific language governing permissions and
13 # limitations under the License.
15 # @author Yunchan Cho (yunchan.cho@samsung.com)
17 SET(TARGET_NAME ${TARGET_CORE_UTIL})
18 SET(DEPS ${TARGET_NAME}_DEPS)
20 PKG_CHECK_MODULES(${DEPS}
24 ADD_DEFINITIONS(${${DEPS}_CFLAGS})
27 ${CMAKE_CURRENT_SOURCE_DIR}/Log.cpp
31 ${${DEPS}_INCLUDE_DIRS}
32 ${CMAKE_CURRENT_SOURCE_DIR}
35 INCLUDE_DIRECTORIES(${HEADERS})
37 ADD_LIBRARY(${TARGET_NAME} STATIC ${SRCS})
39 SET_TARGET_PROPERTIES(${TARGET_NAME} PROPERTIES
41 LINK_FLAGS "-Wl,--as-needed -Wl,--hash-style=both"
44 SET_TARGET_PROPERTIES(${TARGET_NAME}
46 SOVERSION ${CMAKE_PROJECT_API_VERSION}
47 VERSION ${CMAKE_PROJECT_VERSION}
50 TARGET_LINK_LIBRARIES(${TARGET_NAME}
54 INCLUDE_DIRECTORIES(${HEADERS})
55 GET_FILENAME_COMPONENT(CURRENT_DIR_NAME ${CMAKE_CURRENT_SOURCE_DIR} NAME)
56 GET_FILENAME_COMPONENT(PARENT_DIR_ABSOLUTE_PATH ${CMAKE_CURRENT_SOURCE_DIR} PATH)
57 GET_FILENAME_COMPONENT(PARENT_DIR_NAME ${PARENT_DIR_ABSOLUTE_PATH} NAME)
59 INSTALL_FILE(Noncopyable.h include/${PROJECT_NAME}/${PARENT_DIR_NAME}/${CURRENT_DIR_NAME})
60 INSTALL_FILE(Log.h include/${PROJECT_NAME}/${PARENT_DIR_NAME}/${CURRENT_DIR_NAME})