1
0
mirror of https://github.com/VCMP-SqMod/SqMod.git synced 2024-11-08 00:37:15 +01:00

Port legacy SQLite implementation.

This commit is contained in:
Sandu Liviu Catalin 2021-06-12 17:51:01 +03:00
parent 82dfda13cb
commit f5592208fa
4 changed files with 5668 additions and 0 deletions

View File

@ -141,10 +141,13 @@ if(ENABLE_DATA_SQLITE)
# We need to make sqlite3.h available for include. Ugly but POCO doesn't expose this directly.
target_include_directories(SqModule PRIVATE "${PROJECT_SOURCE_DIR}/vendor/POCO/Data/SQLite/src")
endif()
message(STATUS SQLite was enabled)
# Link the libraries
target_link_libraries(SqModule Poco::DataSQLite)
# Inform the plug-in that it can make use of this library
target_compile_definitions(SqModule PRIVATE SQMOD_POCO_HAS_SQLITE=1)
# Include legacy implementation sources
target_sources(SqModule PRIVATE Library/SQLite.hpp Library/SQLite.cpp)
endif()
# Does POCO have MySLQ support?
find_package(MySQL)

3156
module/Library/SQLite.cpp Normal file

File diff suppressed because it is too large Load Diff

2503
module/Library/SQLite.hpp Normal file

File diff suppressed because it is too large Load Diff

View File

@ -41,6 +41,9 @@ extern void Register_String(HSQUIRRELVM vm);
extern void Register_System(HSQUIRRELVM vm);
extern void Register_Utils(HSQUIRRELVM vm);
extern void Register_ZMQ(HSQUIRRELVM vm);
#ifdef SQMOD_POCO_HAS_SQLITE
extern void Register_SQLite(HSQUIRRELVM vm);
#endif
// ------------------------------------------------------------------------------------------------
extern void Register_POCO(HSQUIRRELVM vm);
@ -98,6 +101,9 @@ bool RegisterAPI(HSQUIRRELVM vm)
Register_System(vm);
Register_Utils(vm);
Register_ZMQ(vm);
#ifdef SQMOD_POCO_HAS_SQLITE
Register_SQLite(vm);
#endif
Register_POCO(vm);