2017-03-23 16:10:45 +00:00
|
|
|
find_packages(QLITE_PACKAGES REQUIRED
|
|
|
|
Gee
|
|
|
|
GLib
|
|
|
|
GObject
|
|
|
|
SQLite3
|
2017-03-02 14:37:32 +00:00
|
|
|
)
|
|
|
|
|
|
|
|
vala_precompile(QLITE_VALA_C
|
|
|
|
SOURCES
|
|
|
|
"src/database.vala"
|
|
|
|
"src/table.vala"
|
|
|
|
"src/column.vala"
|
|
|
|
"src/row.vala"
|
|
|
|
|
|
|
|
"src/statement_builder.vala"
|
2017-08-25 22:05:36 +00:00
|
|
|
"src/delete_builder.vala"
|
2017-03-02 14:37:32 +00:00
|
|
|
"src/insert_builder.vala"
|
2017-08-25 22:05:36 +00:00
|
|
|
"src/query_builder.vala"
|
2017-03-02 14:37:32 +00:00
|
|
|
"src/update_builder.vala"
|
2017-08-25 22:05:36 +00:00
|
|
|
"src/upsert_builder.vala"
|
2017-03-02 14:37:32 +00:00
|
|
|
PACKAGES
|
|
|
|
${QLITE_PACKAGES}
|
|
|
|
GENERATE_VAPI
|
|
|
|
qlite
|
|
|
|
GENERATE_HEADER
|
|
|
|
qlite
|
|
|
|
)
|
|
|
|
|
|
|
|
add_custom_target(qlite-vapi
|
|
|
|
DEPENDS
|
2017-03-11 22:20:25 +00:00
|
|
|
${CMAKE_BINARY_DIR}/exports/qlite.vapi
|
2017-03-23 16:10:45 +00:00
|
|
|
${CMAKE_BINARY_DIR}/exports/qlite.deps
|
2017-03-02 14:37:32 +00:00
|
|
|
)
|
|
|
|
|
2017-04-23 08:01:40 +00:00
|
|
|
add_definitions(${VALA_CFLAGS})
|
|
|
|
add_library(qlite SHARED ${QLITE_VALA_C})
|
|
|
|
add_dependencies(qlite qlite-vapi)
|
|
|
|
target_link_libraries(qlite ${QLITE_PACKAGES})
|
|
|
|
set_target_properties(qlite PROPERTIES VERSION 0.1 SOVERSION 0)
|
|
|
|
|
2017-03-23 16:10:45 +00:00
|
|
|
install(TARGETS qlite ${TARGET_INSTALL})
|
|
|
|
install(FILES ${CMAKE_BINARY_DIR}/exports/qlite.vapi ${CMAKE_BINARY_DIR}/exports/qlite.deps DESTINATION ${VAPI_INSTALL_DIR})
|
|
|
|
install(FILES ${CMAKE_BINARY_DIR}/exports/qlite.h DESTINATION ${INCLUDE_INSTALL_DIR})
|