This PR adds a proof-of-concept CMakeLists.txt - this CMakeLists.txt will work for Windows and Linux (I tested under Ubuntu 22.04 Desktop edition in a virtual machine)
To build with cmake on windows with icu support, specify -DWITH_ICU= on the command line. This should be the folder that has the include, lib, and bin folders or include, lib64, and bin64 folders when building x64.
The build.bat is included as an example of how to build 32-bit Debug/Release and 64-bit Debug/Release and have the build binaries/libs go to separate folders.
Additionally, I found that I cannot compile with the following flags:
SQLITE_ENABLE_SERIES
SQLITE_ENABLE_REGEXP
Attempting to compile with those flags results in the following compile erros (both on windows/msvc 2022 and linux/ubuntu):
Building Custom Rule D:/Git/SQLite3MultipleCiphers/CMakeLists.txt
sqlite3mc.c
sqlite3mc_lib_mt.vcxproj -> D:\Git\SQLite3MultipleCiphers\x64\Release\sqlite3mc_lib_mt.lib
Building Custom Rule D:/Git/SQLite3MultipleCiphers/CMakeLists.txt
sqlite3mc_lib_mt.lib(sqlite3mc.obj) : error LNK2005: sqlite3_regexp_init already defined in shell.obj [D:\Git\SQLite3MultipleCiphers\x64\sqlite3mc_shell.vcxproj]
sqlite3mc_lib_mt.lib(sqlite3mc.obj) : error LNK2005: sqlite3_series_init already defined in shell.obj [D:\Git\SQLite3MultipleCiphers\x64\sqlite3mc_shell.vcxproj]
Creating library D:/Git/SQLite3MultipleCiphers/x64/Release/sqlite3mc_shell.lib and object D:/Git/SQLite3MultipleCiphers/x64/Release/sqlite3mc_shell.exp
D:\Git\SQLite3MultipleCiphers\x64\Release\sqlite3mc_shell.exe : fatal error LNK1169: one or more multiply defined symbols found [D:\Git\SQLite3MultipleCiphers\x64\sqlite3mc_shell.vcxproj]
This PR adds a proof-of-concept CMakeLists.txt - this CMakeLists.txt will work for Windows and Linux (I tested under Ubuntu 22.04 Desktop edition in a virtual machine)
To build with cmake on windows with icu support, specify -DWITH_ICU= on the command line. This should be the folder that has the include, lib, and bin folders or include, lib64, and bin64 folders when building x64.
The build.bat is included as an example of how to build 32-bit Debug/Release and 64-bit Debug/Release and have the build binaries/libs go to separate folders.
Additionally, I found that I cannot compile with the following flags: SQLITE_ENABLE_SERIES SQLITE_ENABLE_REGEXP
Attempting to compile with those flags results in the following compile erros (both on windows/msvc 2022 and linux/ubuntu):
Building Custom Rule D:/Git/SQLite3MultipleCiphers/CMakeLists.txt sqlite3mc.c sqlite3mc_lib_mt.vcxproj -> D:\Git\SQLite3MultipleCiphers\x64\Release\sqlite3mc_lib_mt.lib Building Custom Rule D:/Git/SQLite3MultipleCiphers/CMakeLists.txt sqlite3mc_lib_mt.lib(sqlite3mc.obj) : error LNK2005: sqlite3_regexp_init already defined in shell.obj [D:\Git\SQLite3MultipleCiphers\x64\sqlite3mc_shell.vcxproj] sqlite3mc_lib_mt.lib(sqlite3mc.obj) : error LNK2005: sqlite3_series_init already defined in shell.obj [D:\Git\SQLite3MultipleCiphers\x64\sqlite3mc_shell.vcxproj] Creating library D:/Git/SQLite3MultipleCiphers/x64/Release/sqlite3mc_shell.lib and object D:/Git/SQLite3MultipleCiphers/x64/Release/sqlite3mc_shell.exp D:\Git\SQLite3MultipleCiphers\x64\Release\sqlite3mc_shell.exe : fatal error LNK1169: one or more multiply defined symbols found [D:\Git\SQLite3MultipleCiphers\x64\sqlite3mc_shell.vcxproj]