2011-09-14 13:23:36 +00:00
|
|
|
set(LIBNAME "PocoDataSQLite")
|
2012-01-08 19:10:15 +00:00
|
|
|
set(LIBNAME "${LIBNAME}${LIB_EXT}")
|
2009-02-15 15:49:19 +00:00
|
|
|
|
|
|
|
include_directories( include src )
|
|
|
|
|
2012-02-06 18:35:26 +00:00
|
|
|
set(SRCS
|
|
|
|
src/Binder.cpp
|
|
|
|
src/Connector.cpp
|
|
|
|
src/Extractor.cpp
|
|
|
|
src/SQLiteException.cpp
|
|
|
|
src/SQLiteStatementImpl.cpp
|
|
|
|
src/SessionImpl.cpp
|
|
|
|
src/Utility.cpp
|
|
|
|
)
|
|
|
|
|
|
|
|
|
|
|
|
if (!POCO_UNBUNDLED)
|
|
|
|
set(SRCS "${SRCS} src/sqlite3.c")
|
|
|
|
set(DATASQLITELIBS PocoData${LIB_EXT} PocoFoundation${LIB_EXT} )
|
|
|
|
else()
|
|
|
|
set(DATASQLITELIBS PocoData${LIB_EXT} PocoFoundation${LIB_EXT} sqlite3)
|
|
|
|
endif()
|
2009-02-15 15:49:19 +00:00
|
|
|
|
2011-09-14 13:23:36 +00:00
|
|
|
add_definitions(-DSQLITE_THREADSAFE=1 -DSQLITE_DISABLE_LFS -DSQLITE_OMIT_UTF16 -DSQLITE_OMIT_PROGRESS_CALLBACK -DSQLITE_OMIT_COMPLETE -DSQLITE_OMIT_TCL_VARIABLE -DSQLITE_OMIT_DEPRECATED)
|
2009-02-15 15:49:19 +00:00
|
|
|
|
|
|
|
add_library( ${LIBNAME} ${LIB_MODE} ${SRCS} )
|
|
|
|
set_target_properties( ${LIBNAME}
|
2012-01-07 13:45:03 +00:00
|
|
|
PROPERTIES
|
2011-09-15 08:31:51 +00:00
|
|
|
VERSION ${SHARED_LIBRARY_VERSION} SOVERSION ${SHARED_LIBRARY_VERSION} )
|
2012-02-06 18:35:26 +00:00
|
|
|
target_link_libraries( ${LIBNAME} ${DATASQLITELIBS} )
|
2009-02-15 15:49:19 +00:00
|
|
|
|
2009-02-18 20:47:32 +00:00
|
|
|
install(
|
|
|
|
DIRECTORY include/Poco
|
|
|
|
DESTINATION include
|
2009-04-27 19:22:30 +00:00
|
|
|
PATTERN ".svn" EXCLUDE
|
2009-02-18 20:47:32 +00:00
|
|
|
)
|
|
|
|
|
|
|
|
install(
|
2012-01-07 13:45:03 +00:00
|
|
|
TARGETS ${LIBNAME}
|
2009-02-18 20:47:32 +00:00
|
|
|
DESTINATION lib
|
|
|
|
)
|
|
|
|
|
2011-01-22 11:46:03 +00:00
|
|
|
if (ENABLE_TESTS)
|
|
|
|
add_subdirectory(testsuite)
|
|
|
|
endif ()
|
|
|
|
|