Integrate the database so into the server so 30/127930/1
authorMu-Woong Lee <muwoong.lee@samsung.com>
Tue, 2 May 2017 11:30:29 +0000 (20:30 +0900)
committerMu-Woong Lee <muwoong.lee@samsung.com>
Tue, 2 May 2017 11:30:29 +0000 (20:30 +0900)
We will not support api-side database creations (at least in Tizen 4.0).

Change-Id: I3048c8ea8f95169124572ed1128131c62ee56837
Signed-off-by: Mu-Woong Lee <muwoong.lee@samsung.com>
CMakeLists.txt
src/client/CMakeLists.txt
src/database/CMakeLists.txt [deleted file]
src/server/CMakeLists.txt
src/server/Database.cpp [moved from src/database/Database.cpp with 100% similarity]
src/server/PlatformDatabase.cpp

index d9a4ab4..f84a64f 100644 (file)
@@ -29,9 +29,7 @@ INSTALL(
 
 SET(target_prefix "context")
 SET(target_shared "${target_prefix}-shared")
-SET(target_database "${target_prefix}-database")
 
 ADD_SUBDIRECTORY(src/shared)
-ADD_SUBDIRECTORY(src/database)
 ADD_SUBDIRECTORY(src/client)
 ADD_SUBDIRECTORY(src/server)
index 2ea4d7e..57c008a 100644 (file)
@@ -21,7 +21,7 @@ SET_TARGET_PROPERTIES(${target} PROPERTIES VERSION ${FULLVER})
 SET(PC_NAME "${PROJECT_NAME}-client")
 SET(PC_DESCRIPTION "Tizen Context-Service Internal Shared Library for Clients")
 SET(PC_REQUIRED ${DEPS})
-SET(PC_LDFLAGS "-l${target} -l${target_shared} -l${target_database}")
+SET(PC_LDFLAGS "-l${target} -l${target_shared}")
 
 CONFIGURE_FILE(
        ${CMAKE_SOURCE_DIR}/pkg-config.pc.in
diff --git a/src/database/CMakeLists.txt b/src/database/CMakeLists.txt
deleted file mode 100644 (file)
index 2b7a508..0000000
+++ /dev/null
@@ -1,20 +0,0 @@
-SET(target ${target_database})
-
-SET(DEPS "${DEPS} sqlite3")
-
-FILE(GLOB_RECURSE SRCS *.cpp)
-MESSAGE("Sources: ${SRCS}")
-
-INCLUDE(FindPkgConfig)
-pkg_check_modules(PKG_DATABASE REQUIRED ${DEPS})
-
-FOREACH(flag ${PKG_DATABASE_CFLAGS})
-   SET(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${flag}")
-ENDFOREACH(flag)
-
-ADD_LIBRARY(${target} SHARED ${SRCS})
-TARGET_LINK_LIBRARIES(${target} ${PKG_DATABASE_LDFLAGS} ${target_shared})
-SET_TARGET_PROPERTIES(${target} PROPERTIES SOVERSION ${MAJORVER})
-SET_TARGET_PROPERTIES(${target} PROPERTIES VERSION ${FULLVER})
-
-INSTALL(TARGETS ${target} DESTINATION ${CMAKE_INSTALL_LIBDIR})
index 3ecf139..21c918e 100644 (file)
@@ -13,7 +13,7 @@ FOREACH(flag ${PKG_SERVER_CFLAGS})
 ENDFOREACH(flag)
 
 ADD_LIBRARY(${target} SHARED ${SRCS})
-TARGET_LINK_LIBRARIES(${target} ${LIB_PKG_LDFLAGS} ${target_shared} ${target_database})
+TARGET_LINK_LIBRARIES(${target} ${LIB_PKG_LDFLAGS} ${target_shared})
 SET_TARGET_PROPERTIES(${target} PROPERTIES SOVERSION ${MAJORVER})
 SET_TARGET_PROPERTIES(${target} PROPERTIES VERSION ${FULLVER})
 
@@ -21,7 +21,7 @@ SET_TARGET_PROPERTIES(${target} PROPERTIES VERSION ${FULLVER})
 SET(PC_NAME "${PROJECT_NAME}-server")
 SET(PC_DESCRIPTION "Tizen Context-Service Internal Shared Library for Servers")
 SET(PC_REQUIRED ${DEPS})
-SET(PC_LDFLAGS "-l${target} -l${target_shared} -l${target_database}")
+SET(PC_LDFLAGS "-l${target} -l${target_shared}")
 
 CONFIGURE_FILE(
        ${CMAKE_SOURCE_DIR}/pkg-config.pc.in
index a6e2e5c..6ba6635 100644 (file)
@@ -14,7 +14,6 @@
  * limitations under the License.
  */
 
-#include <sqlite3.h>
 #include <Tuple.h>
 #include <ClientBase.h>
 #include <ServerUtil.h>