1 # Copyright (c) 2011 Samsung Electronics Co., Ltd All Rights Reserved
3 # Licensed under the Apache License, Version 2.0 (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://www.apache.org/licenses/LICENSE-2.0
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.
16 # @file CMakeLists.txt
17 # @author Lukasz Wrzosek (l.wrzosek@samsung.com)
22 ${INSTALLER_SRC_DIR}/wrt-installer
25 SET(WRT_INSTALLER_SOURCES
26 ${WRT_INSTALLER_DIR}/wrt_installer.cpp
27 ${WRT_INSTALLER_DIR}/wrt_installer_api.cpp
28 ${WRT_INSTALLER_DIR}/installer_callbacks_translate.cpp
29 ${WRT_INSTALLER_DIR}/plugin_utils.cpp
30 ${WRT_INSTALLER_DIR}/language_subtag_rst_tree.cpp
31 ${WRT_INSTALLER_DIR}/installer_main_thread.cpp
32 ${WRT_INSTALLER_DIR}/option_parser.cpp
35 PKG_CHECK_MODULES(WRT_INSTALLER_DEPS
41 ${WRT_INSTALLER_DEP_INCLUDES}
42 ${WRT_INSTALLER_INCLUDES}
43 ${WRT_INSTALLER_DEPS_INCLUDE_DIRS}
46 ADD_EXECUTABLE(${TARGET_INSTALLER}
47 ${TARGET_INSTALLER_STATIC_SRC}
48 ${WRT_INSTALLER_SOURCES}
51 ADD_DEFINITIONS("-DSEPARATE_INSTALLER_FOR_DAO") # TODO do not use ifdefs!
52 ADD_DEFINITIONS(${WRT_INSTALLER_DEPS_CFLAGS})
54 TARGET_LINK_LIBRARIES(${TARGET_INSTALLER}
55 ${TARGET_INSTALLER_STATIC}
56 ${WRT_INSTALLER_DEPS_LIBRARIES}
60 SET_TARGET_PROPERTIES(${TARGET_INSTALLER} PROPERTIES
61 LINK_FLAGS "-Wl,--as-needed -Wl,--hash-style=both -Wl"
62 BUILD_WITH_INSTALL_RPATH ON
63 INSTALL_RPATH_USE_LINK_PATH ON
66 INSTALL(TARGETS ${TARGET_INSTALLER} DESTINATION bin)