PROJECT(bt-service-api C)
SET(SRCS
+../include/bt-internal-types.c
bt-common.c
bt-adapter.c
bt-adapter-le.c
bt-avrcp.c
bt-telephony.c
bt-opp-client.c
+bt-map-client.c
bt-obex-server.c
bt-rfcomm-client.c
bt-rfcomm-server.c
bt-gatt-client.c
bt-ipsp.c
bt-dpm.c
-bt-proximity.c)
+bt-proximity.c
+bt-tds.c
+bt-otp.c
+bt-mesh.c)
SET(HEADERS
bluetooth-api.h
bluetooth-telephony-api.h
bluetooth-media-control.h
bluetooth-scmst-api.h
-bluetooth-ipsp-api.h)
+bluetooth-ipsp-api.h
+bluetooth-gatt-server-api.h
+bluetooth-gatt-client-api.h
+bluetooth-mesh-api.h)
SET(PREFIX ${CMAKE_INSTALL_PREFIX})
SET(EXEC_PREFIX "\${prefix}")
SET(PKG_MODULES
dlog
- dbus-glib-1
gobject-2.0
gmodule-2.0
vconf
glib-2.0
gio-2.0
gio-unix-2.0
- dbus-1
+ capi-system-info
)
INCLUDE(FindPkgConfig)
MESSAGE("add -DTARGET")
ENDIF("${ARCH}" STREQUAL "arm")
-ADD_DEFINITIONS("-DHPS_FEATURE")
-ADD_DEFINITIONS("-DTIZEN_DPM_ENABLE")
-ADD_DEFINITIONS("-DTIZEN_DPM_VCONF_ENABLE")
-
-FIND_PROGRAM(MARSHALTOOL NAMES glib-genmarshal)
-EXEC_PROGRAM("${MARSHALTOOL}" ARGS "--prefix=marshal ${CMAKE_CURRENT_SOURCE_DIR}/marshal.list --header > ${CMAKE_CURRENT_SOURCE_DIR}/include/marshal.h")
-EXEC_PROGRAM("${MARSHALTOOL}" ARGS "--prefix=marshal ${CMAKE_CURRENT_SOURCE_DIR}/marshal.list --body > ${CMAKE_CURRENT_SOURCE_DIR}/marshal.c")
-
-FIND_PROGRAM(DBUS_BINDING_TOOL NAMES dbus-binding-tool)
-EXEC_PROGRAM("${DBUS_BINDING_TOOL}" ARGS "--prefix=bt ${CMAKE_CURRENT_SOURCE_DIR}/bt-request-service.xml --mode=glib-client --output=${CMAKE_CURRENT_SOURCE_DIR}/include/bt-request-service.h")
-EXEC_PROGRAM("${DBUS_BINDING_TOOL}" ARGS "--prefix=bluetooth_gatt ${CMAKE_CURRENT_SOURCE_DIR}/bt-gatt.xml --mode=glib-server --output=${CMAKE_CURRENT_SOURCE_DIR}/include/bt-gatt-glue.h")
+#ADD_DEFINITIONS("-DTIZEN_FEATURE_BT_HPS")
+ADD_DEFINITIONS("-DTIZEN_FEATURE_BT_OTP")
+ADD_DEFINITIONS("-DTIZEN_GATT_CLIENT")
ADD_LIBRARY(bluetooth-api SHARED ${SRCS})
SET_TARGET_PROPERTIES(bluetooth-api PROPERTIES SOVERSION ${VERSION_MAJOR})
SET_TARGET_PROPERTIES(bluetooth-api PROPERTIES VERSION ${VERSION})
-TARGET_LINK_LIBRARIES(bluetooth-api ${packages_LDFLAGS})
+TARGET_LINK_LIBRARIES(bluetooth-api ${packages_LDFLAGS} -ldl)
CONFIGURE_FILE(${CMAKE_CURRENT_SOURCE_DIR}/bluetooth-api.pc.in ${CMAKE_CURRENT_BINARY_DIR}/bluetooth-api.pc @ONLY)
INSTALL(FILES ${CMAKE_CURRENT_BINARY_DIR}/bluetooth-api.pc DESTINATION ${LIBDIR}/pkgconfig)
INSTALL(TARGETS bluetooth-api DESTINATION ${LIBDIR} COMPONENT RuntimeLibraries)