tizen 2.4 release
[framework/web/wrt-plugins-common.git] / src / xwalk-module / CMakeLists.txt
1 # Copyright (c) 2011 Samsung Electronics Co., Ltd All Rights Reserved
2 #
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
6 #
7 #        http://www.apache.org/licenses/LICENSE-2.0
8 #
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.
14 #
15
16 # @file     CMakeLists.txt
17 # @author   Lukasz Marek (l.marek@samsung.com)
18 # @version  1.0
19 #
20
21 SET(TARGET_XWALK_MODULE_LIB "wrt-xwalk-module")
22
23 pkg_search_module(webkit2 REQUIRED ewebkit2)
24
25 set(XWALK_MODULE_SRC
26     extension_adapter.cpp
27     extension_manager.cpp
28     extension.cpp
29     xwalk_extension_client.cpp
30     xwalk_extension_module.cpp
31     xwalk_extension_renderer_controller.cpp
32     xwalk_module_system.cpp
33     xwalk_v8tools_module.cpp
34     object_tools_module.cpp
35     js_utils.cpp
36 )
37
38 INCLUDE_DIRECTORIES(
39     ${webkit2_INCLUDE_DIRS}
40 )
41
42 ADD_LIBRARY(${TARGET_XWALK_MODULE_LIB} SHARED
43     ${XWALK_MODULE_SRC}
44 )
45
46 SET_TARGET_PROPERTIES(${TARGET_XWALK_MODULE_LIB} PROPERTIES
47     COMPILE_DEFINITIONS LOG_TAG="WRT_XWALK")
48
49 SET_TARGET_PROPERTIES(${TARGET_XWALK_MODULE_LIB} PROPERTIES
50     COMPILE_FLAGS -fPIC
51     LINK_FLAGS "-Wl,--as-needed -Wl,--hash-style=both"
52 )
53
54 target_link_libraries(${TARGET_XWALK_MODULE_LIB}
55     ${webkit2_LIBRARIES}
56     ${TARGET_PLUGINS_IPC_MESSAGE_LIB}
57 )
58
59 INSTALL(TARGETS ${TARGET_XWALK_MODULE_LIB}
60     DESTINATION lib
61     PERMISSIONS OWNER_READ OWNER_WRITE OWNER_EXECUTE
62     GROUP_READ GROUP_EXECUTE WORLD_READ WORLD_EXECUTE
63 )
64
65 INSTALL(FILES
66     xwalk_extension_renderer_controller.h
67     DESTINATION include/wrt-plugin-loading)
68