1 SET (this_target osp-uifw)
5 ${CMAKE_SOURCE_DIR}/inc
6 ${CMAKE_SOURCE_DIR}/src/app/inc
7 ${CMAKE_SOURCE_DIR}/src/graphics/inc
8 ${CMAKE_SOURCE_DIR}/src/ui
9 ${CMAKE_SOURCE_DIR}/src/ui/inc
10 ${CMAKE_SOURCE_DIR}/src/ui/controls
14 /usr/include/osp/media
15 /usr/include/osp/system
18 SET (${this_target}_SOURCE_FILES
19 ${CMAKE_SOURCE_DIR}/src/app/FAppUiApp.cpp
20 ${CMAKE_SOURCE_DIR}/src/app/FApp_UiAppImpl.cpp
21 ${CMAKE_SOURCE_DIR}/src/app/FApp_AppFrame.cpp
22 ${CMAKE_SOURCE_DIR}/src/app/FApp_AppResourceBitmap.cpp
23 ${CMAKE_SOURCE_DIR}/src/app/FApp_AppResourceBitmapUtil.cpp
26 SET(EXTRA_CFLAGS "${EXTRA_CFLAGS} -Wall" )
28 ## SET C COMPILER FLAGS
29 SET(CMAKE_C_FLAGS "${OSP_DEBUG_FLAGS} ${OSP_OPT_FLAGS} ${CMAKE_C_FLAGS} ${EXTRA_CFLAGS} ${OSP_COMPILER_FLAGS}")
31 ## SET CPP COMPILER FLAGS
32 SET(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -fvisibility=hidden")
33 SET(CMAKE_CXX_FLAGS "${OSP_DEBUG_FLAGS} ${OSP_OPT_FLAGS} ${CMAKE_CXX_FLAGS} ${EXTRA_CFLAGS} ${OSP_COMPILER_FLAGS}")
36 ADD_LIBRARY (${this_target} SHARED ${${this_target}_SOURCE_FILES})
38 SET(STATIC_LIBS ui graphics opengl)
40 ADD_DEPENDENCIES(${this_target} ${STATIC_LIBS})
42 MACRO(OSP_ADD_OBJS_IN_ARCHIVE archives)
43 SET(LINK_OBJECTS_IN_ARCHIVE)
44 FOREACH(archive ${ARGV})
45 SET(LINK_OBJECTS_IN_ARCHIVE "${LINK_OBJECTS_IN_ARCHIVE} -l${archive}")
47 SET(CMAKE_SHARED_LINKER_FLAGS "${CMAKE_SHARED_LINKER_FLAGS} -Wl,--whole-archive ${LINK_OBJECTS_IN_ARCHIVE} -Wl,-no-whole-archive")
48 ENDMACRO(OSP_ADD_OBJS_IN_ARCHIVE)
50 OSP_ADD_OBJS_IN_ARCHIVE(${STATIC_LIBS})
52 SET(CMAKE_SHARED_LINKER_FLAGS "${CMAKE_SHARED_LINKER_FLAGS} -Wl,--no-undefined -Wl,--as-needed")
54 TARGET_LINK_LIBRARIES( ${this_target} ${STATIC_LIBS})
55 TARGET_LINK_LIBRARIES(${this_target} "-L/usr/lib/osp -losp-appfw" )
56 TARGET_LINK_LIBRARIES(${this_target} "-losp-image-core" )
57 TARGET_LINK_LIBRARIES(${this_target} "-losp-speech-tts" )
58 TARGET_LINK_LIBRARIES(${this_target} "-lcapi-appfw-application" )
59 TARGET_LINK_LIBRARIES(${this_target} "-lappcore-common" )
60 TARGET_LINK_LIBRARIES(${this_target} "-lappcore-efl" )
61 TARGET_LINK_LIBRARIES(${this_target} "-lappsvc" )
62 TARGET_LINK_LIBRARIES(${this_target} "-lsensor" )
63 TARGET_LINK_LIBRARIES(${this_target} "-lelementary" )
64 TARGET_LINK_LIBRARIES(${this_target} "-lX11" )
65 TARGET_LINK_LIBRARIES(${this_target} "-lXdamage" )
66 TARGET_LINK_LIBRARIES(${this_target} "-lvconf" )
67 TARGET_LINK_LIBRARIES(${this_target} "-ldlog" )
68 TARGET_LINK_LIBRARIES(${this_target} "-lpthread" )
69 TARGET_LINK_LIBRARIES(${this_target} "-lecore" )
70 TARGET_LINK_LIBRARIES(${this_target} "-levas" )
71 TARGET_LINK_LIBRARIES(${this_target} "-leina" )
72 TARGET_LINK_LIBRARIES(${this_target} "-lecore_evas" )
73 TARGET_LINK_LIBRARIES(${this_target} "-lecore_x" )
74 TARGET_LINK_LIBRARIES(${this_target} "-lecore_imf" )
75 TARGET_LINK_LIBRARIES(${this_target} "-lecore_imf_evas" )
76 TARGET_LINK_LIBRARIES(${this_target} "-lecore_input" )
77 TARGET_LINK_LIBRARIES(${this_target} "-lxml2" )
78 TARGET_LINK_LIBRARIES(${this_target} "-lfontconfig" )
79 TARGET_LINK_LIBRARIES(${this_target} "-lcairo" )
80 TARGET_LINK_LIBRARIES(${this_target} "-lpixman-1" )
81 TARGET_LINK_LIBRARIES(${this_target} "-licuuc" )
82 TARGET_LINK_LIBRARIES(${this_target} "-lpangocairo-1.0" )
83 TARGET_LINK_LIBRARIES(${this_target} "-lgobject-2.0" )
84 TARGET_LINK_LIBRARIES(${this_target} "-lpango-1.0" )
85 TARGET_LINK_LIBRARIES(${this_target} "-lglib-2.0" )
86 TARGET_LINK_LIBRARIES(${this_target} "-lfreetype" )
87 TARGET_LINK_LIBRARIES(${this_target} "-lfribidi" )
88 TARGET_LINK_LIBRARIES(${this_target} "-lharfbuzz" )
89 TARGET_LINK_LIBRARIES(${this_target} "-ldl" )
90 TARGET_LINK_LIBRARIES(${this_target} "-lXext" )
91 TARGET_LINK_LIBRARIES(${this_target} "-lEGL" )
92 TARGET_LINK_LIBRARIES(${this_target} "-lXv" )
93 TARGET_LINK_LIBRARIES(${this_target} "-ltts" )
94 TARGET_LINK_LIBRARIES(${this_target} "-lfeedback" )
96 TARGET_LINK_LIBRARIES(${this_target} "-ldri2" )
97 TARGET_LINK_LIBRARIES(${this_target} "-ldrm" )
98 TARGET_LINK_LIBRARIES(${this_target} "-ltbm" )
100 TARGET_LINK_LIBRARIES(${this_target} "-llua" )
101 TARGET_LINK_LIBRARIES(${this_target} "-ltolua++" )
102 TARGET_LINK_LIBRARIES(${this_target} "-lcapi-system-runtime-info")
103 TARGET_LINK_LIBRARIES(${this_target} "-lutilX" )
104 TARGET_LINK_LIBRARIES(${this_target} "-lXtst" )
105 TARGET_LINK_LIBRARIES(${this_target} "-lchromium" )
107 SET_TARGET_PROPERTIES(${this_target}
110 SOVERSION ${MAJORVER}
111 CLEAN_DIRECT_OUTPUT 1
113 ADD_CUSTOM_COMMAND(TARGET ${this_target}
115 COMMAND ${CMAKE_COMMAND} -E copy ${LIBRARY_OUTPUT_PATH}/${CMAKE_SHARED_LIBRARY_PREFIX}${this_target}${CMAKE_SHARED_LIBRARY_SUFFIX} ${LIBRARY_OUTPUT_PATH}/debug/${CMAKE_SHARED_LIBRARY_PREFIX}${this_target}${CMAKE_SHARED_LIBRARY_SUFFIX}.${FULLVER}
116 COMMAND ${CMAKE_COMMAND} -E create_symlink ${CMAKE_SHARED_LIBRARY_PREFIX}${this_target}${CMAKE_SHARED_LIBRARY_SUFFIX}.${FULLVER} ${LIBRARY_OUTPUT_PATH}/debug/${CMAKE_SHARED_LIBRARY_PREFIX}${this_target}${CMAKE_SHARED_LIBRARY_SUFFIX}.${MAJORVER}
117 COMMAND ${CMAKE_STRIP} --strip-unneeded ${LIBRARY_OUTPUT_PATH}/${CMAKE_SHARED_LIBRARY_PREFIX}${this_target}${CMAKE_SHARED_LIBRARY_SUFFIX}
118 COMMENT "strip ${this_target}"
121 SET(PC_NAME ${this_target})
122 SET(PC_REQUIRED ${pc_requires})
123 SET(PC_LDFLAGS -l${this_target})
126 CONFIGURE_FILE(${CMAKE_SOURCE_DIR}/${this_target}.pc.in ${CMAKE_SOURCE_DIR}/${this_target}.pc @ONLY)