Removed compilation warnings
[platform/framework/web/wrt.git] / src / 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 Wrzosek (l.wrzosek@samsung.com)
18 # @version     1.0
19 #
20
21 #it is here, so no INCLUDE_DIRS and DEFINITIONS are passed there
22 ADD_SUBDIRECTORY(view)
23
24
25 SET(WRT_SRC_DIR
26    ${PROJECT_SOURCE_DIR}/src
27    )
28
29 SET(WRT_CORE_BASE_SOURCES
30     ${WRT_SRC_DIR}/domain/global_context.cpp
31     ${WRT_SRC_DIR}/domain/widget_data_types.cpp
32     ${WRT_SRC_DIR}/domain/widget_deserialize_model.cpp
33     ${WRT_SRC_DIR}/domain/widget_localize_model.cpp
34     ${WRT_SRC_DIR}/domain/localization_setting.cpp
35     ${WRT_SRC_DIR}/domain/widget_model.cpp
36     ${WRT_SRC_DIR}/domain/main_thread.cpp
37     )
38
39 SET(WRT_CORE_INCLUDES
40     ${WRT_SRC_DIR}/plugin-service
41     ${WRT_SRC_DIR}/common
42     ${WRT_SRC_DIR}/utils
43     ${WRT_SRC_DIR}/orm
44     ${WRT_SRC_DIR}/configuration
45     ${WRT_SRC_DIR}/domain
46     ${WRT_SRC_DIR}/localization
47     ${WRT_SRC_DIR}/profiling
48     ${WRT_SRC_DIR}/global_logic
49     ${WRT_SRC_DIR}/ui
50     ${WRT_SRC_DIR}/smack
51     ${WRT_SRC_DIR}/view
52     )
53
54 SET(WRT_PLUGIN_LOADING_DIR
55     ${WRT_SRC_DIR}/plugin-service/plugin-loading/
56    )
57
58
59 SET(PLUGIN_LOADING_INCLUDES
60   ${WRT_PLUGIN_LOADING_DIR}
61 )
62
63 SET(WRT_BASIC_DEP
64     openssl
65     libpcrecpp
66     dpl-popup-efl
67     dpl-efl
68     cert-svc-vcore
69     dpl-dbus-efl
70     dpl-event-efl
71     dpl-utils-efl
72     glib-2.0
73     gthread-2.0
74     edje
75     ecore
76     ecore-x
77     evas
78     eina
79     ewebkit2
80     elementary
81     vconf
82     cert-svc
83     libsoup-2.4
84     ui-gadget-1
85     secure-storage
86     libiri
87     appsvc
88     security-core
89     security-client
90     wrt-popup-runner
91 )
92
93 IF(SMACK_ENABLED)
94   LIST(APPEND WRT_BASIC_DEP libprivilege-control)
95 ENDIF(SMACK_ENABLED)
96
97 PKG_CHECK_MODULES(WRT_ENGINE_DEPS
98     ${WRT_BASIC_DEP}
99     REQUIRED)
100
101 SET(WRT_ENGINE_INCLUDE_DIRS
102     ${WRT_CORE_INCLUDES}
103     ${PLUGIN_LOADING_INCLUDES}
104     ${WRT_ENGINE_DEPS_INCLUDE_DIRS}
105 )
106
107 #wrt-engine-static
108 ADD_DEFINITIONS(${WRT_ENGINE_DEPS_CFLAGS})
109 ADD_DEFINITIONS(${WRT_ENGINE_DEPS_CFLAGS_OTHER})
110 INCLUDE_DIRECTORIES(${WRT_ENGINE_INCLUDE_DIRS})
111
112 ADD_LIBRARY(${TARGET_WRT_ENGINE_STATIC} STATIC
113     ${WRT_CORE_BASE_SOURCES}
114 )
115
116 SET_TARGET_PROPERTIES(${TARGET_WRT_ENGINE_STATIC} PROPERTIES
117     SOVERSION ${PROJECT_API_VERSION}
118     VERSION ${PROJECT_VERSION})
119
120 SET_TARGET_PROPERTIES(${TARGET_WRT_ENGINE_STATIC} PROPERTIES
121     COMPILE_FLAGS -fPIC)
122 SET_TARGET_PROPERTIES(${TARGET_WRT_ENGINE_STATIC} PROPERTIES
123     COMPILE_FLAGS "-include profiling_util.h")
124
125 TARGET_LINK_LIBRARIES(${TARGET_WRT_ENGINE_STATIC}
126     ${TARGET_WRT_DAO_RW_LIB}
127     ${PROF_LIB}
128     )
129
130 INSTALL(FILES
131     ${WRT_SRC_DIR}/domain/widget_model.h
132     DESTINATION include/${PROJECT_NAME}
133 )
134
135 INSTALL(FILES
136     ${WRT_SRC_DIR}/domain/widget_data_types.h
137     DESTINATION include/${PROJECT_NAME}
138 )
139
140 ADD_SUBDIRECTORY(api_new)
141 ADD_SUBDIRECTORY(wrt-client)
142 ADD_SUBDIRECTORY(wrt-launcher)
143 ADD_SUBDIRECTORY(plugin-service)
144 ADD_SUBDIRECTORY(profiling)