Replace append to insert in String, since the arabic locale
[platform/framework/native/appfw.git] / CMakeLists.txt
1 CMAKE_MINIMUM_REQUIRED(VERSION 2.6)
2
3 SET(CMAKE_INSTALL_PREFIX /usr)
4 SET(PREFIX ${CMAKE_INSTALL_PREFIX})
5
6 ## OUTPUT PATHS
7 SET(LIBRARY_OUTPUT_PATH ${CMAKE_SOURCE_DIR}/cmake_build_tmp/output/osp)
8 SET(ROOT_DIR ${CMAKE_SOURCE_DIR}/cmake_build_tmp/output)
9
10 ## Disable build rpath 
11 SET(CMAKE_SKIP_BUILD_RPATH TRUE)
12
13 IF(SBS OR OBS)
14 ADD_DEFINITIONS("-D_EXCEPT_DEPENDENCY_")
15 ENDIF(SBS OR OBS)
16
17 IF(SBS)
18 ADD_DEFINITIONS("-D_SBS_")
19 ENDIF(SBS)
20
21 ## Set Assembly Compiler
22 #SET(CMAKE_ASM_COMPILER "${CMAKE_C_COMPILER}")
23         
24 SET(CMAKE_ASM_COMPILER_ARG1 "${CPPFLAGS} -c")
25 ENABLE_LANGUAGE(ASM)
26         
27 ## LIBRARY PATH
28 LINK_DIRECTORIES (${LIBRARY_OUTPUT_PATH})
29
30 ADD_SUBDIRECTORY(src)
31
32 INSTALL(FILES ${CMAKE_SOURCE_DIR}/osp-appfw.pc DESTINATION lib/pkgconfig)
33 INSTALL(FILES ${CMAKE_SOURCE_DIR}/osp-appfw-server.pc DESTINATION lib/pkgconfig)
34 INSTALL(FILES ${CMAKE_SOURCE_DIR}/res/common/etc/ld.so.conf.d/osp.conf DESTINATION ../etc/ld.so.conf.d)
35
36 INSTALL(DIRECTORY ${CMAKE_SOURCE_DIR}/cmake_build_tmp/output/target/generic/root/usr/share/locale DESTINATION share)
37 INSTALL(DIRECTORY ${LIBRARY_OUTPUT_PATH}/ DESTINATION lib/osp 
38                 FILES_MATCHING PATTERN "libosp-appfw.so*"
39                 PERMISSIONS OWNER_EXECUTE OWNER_WRITE OWNER_READ                      
40                     GROUP_EXECUTE GROUP_READ
41                     WORLD_EXECUTE WORLD_READ)
42 INSTALL(DIRECTORY ${LIBRARY_OUTPUT_PATH}/ DESTINATION lib/osp-server 
43                 FILES_MATCHING PATTERN "libosp-appfw-server.so*" 
44                 PERMISSIONS OWNER_EXECUTE OWNER_WRITE OWNER_READ                      
45                     GROUP_EXECUTE GROUP_READ
46                     WORLD_EXECUTE WORLD_READ)
47 INSTALL(DIRECTORY ${LIBRARY_OUTPUT_PATH}/debug/ DESTINATION lib/osp/debug 
48                 FILES_MATCHING PATTERN "*" PATTERN "libosp-appfw-server.so*" EXCLUDE
49                 PERMISSIONS OWNER_EXECUTE OWNER_WRITE OWNER_READ                                          
50                                         GROUP_EXECUTE GROUP_READ
51                                         WORLD_EXECUTE WORLD_READ)
52                                         
53 INSTALL(DIRECTORY ${CMAKE_SOURCE_DIR}/res/common/opt/usr/share/.osp-compat/share DESTINATION ../opt/usr/share/.osp-compat)
54 INSTALL(DIRECTORY ${CMAKE_SOURCE_DIR}/res/common/usr/share/osp DESTINATION ../usr/share FILES_MATCHING PATTERN ".privilege-description.db")
55 INSTALL(DIRECTORY ${CMAKE_SOURCE_DIR}/res/common/usr/share/osp DESTINATION ../usr/share FILES_MATCHING PATTERN ".external-privilege.ini")
56 INSTALL(DIRECTORY ${CMAKE_SOURCE_DIR}/res/common/opt/usr/etc DESTINATION ../opt/usr)
57 IF("${ARCH}" MATCHES "arm")
58   INSTALL(DIRECTORY ${CMAKE_SOURCE_DIR}/res/arm/usr/etc DESTINATION ../usr)
59 ELSEIF("${ARCH}" MATCHES "x86")
60   INSTALL(DIRECTORY ${CMAKE_SOURCE_DIR}/res/x86/usr/etc DESTINATION ../usr)
61 ENDIF("${ARCH}" MATCHES "arm")
62
63 INSTALL(DIRECTORY ${CMAKE_SOURCE_DIR}/inc/ DESTINATION include/osp FILES_MATCHING PATTERN "*.h" PATTERN "*.hpp")
64 INSTALL(DIRECTORY ${CMAKE_SOURCE_DIR}/src/app/inc/ DESTINATION include/osp/app FILES_MATCHING PATTERN "*.h")
65 INSTALL(DIRECTORY ${CMAKE_SOURCE_DIR}/src/base/inc/ DESTINATION include/osp/base FILES_MATCHING PATTERN "*.h")
66 INSTALL(DIRECTORY ${CMAKE_SOURCE_DIR}/src/io/inc/ DESTINATION include/osp/io FILES_MATCHING PATTERN "*.h")
67 INSTALL(DIRECTORY ${CMAKE_SOURCE_DIR}/src/locales/inc/ DESTINATION include/osp/locales FILES_MATCHING PATTERN "*.h")
68 INSTALL(DIRECTORY ${CMAKE_SOURCE_DIR}/src/security/inc/ DESTINATION include/osp/security FILES_MATCHING PATTERN "*.h")
69 INSTALL(DIRECTORY ${CMAKE_SOURCE_DIR}/src/system/inc/ DESTINATION include/osp/system FILES_MATCHING PATTERN "*.h")
70 INSTALL(DIRECTORY ${CMAKE_SOURCE_DIR}/src/text/inc/ DESTINATION include/osp/text FILES_MATCHING PATTERN "*.h")
71 INSTALL(DIRECTORY ${CMAKE_SOURCE_DIR}/src/server/inc/ DESTINATION include/osp/server/ FILES_MATCHING PATTERN "*.h")