Closed yurivict closed 3 weeks ago
Hi @yurivict, thanks for the report. Is this a regression of 3.3.2 from 3.3.1? Can you provide any other useful context, like the CMake logs, OS and SQLite lib informations? Sébastien
3.3.0 and 3.3.1 also had the same problem.
cmake logs:
===> Configuring for sqlitecpp-3.3.2
===> Performing out-of-source build
/bin/mkdir -p /usr/ports/databases/sqlitecpp/work/.build
-- The C compiler identification is Clang 18.1.5
-- The CXX compiler identification is Clang 18.1.5
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Check for working C compiler: /usr/local/libexec/ccache/cc - skipped
-- Detecting C compile features
-- Detecting C compile features - done
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Check for working CXX compiler: /usr/local/libexec/ccache/c++ - skipped
-- Detecting CXX compile features
-- Detecting CXX compile features - done
-- Using c++ standard c++11
-- CMake version: 3.29.6
-- Project version: 3.3.2
-- Using Stack Protection hardening
-- CMAKE_CXX_COMPILER '/usr/local/libexec/ccache/c++' 'Clang' '18.1.5'
-- CMAKE_CXX_FLAGS '-O2 -pipe -fstack-protector-strong -fno-strict-aliasing -Wall -Wextra -Wpedantic -Wswitch-enum -Wshadow -Wno-long-long'
-- CMAKE_CXX_FLAGS_RELEASE '-O2 -pipe -fstack-protector-strong -fno-strict-aliasing -DNDEBUG'
-- Found SQLite3: /usr/local/include (found version "3.46.0")
-- Link to sqlite3 system library
-- Performing Test CMAKE_HAVE_LIBC_PTHREAD
-- Performing Test CMAKE_HAVE_LIBC_PTHREAD - Failed
-- Found Threads: TRUE
-- SQLITECPP_RUN_CPPLINT OFF
-- Found Cppcheck: /usr/local/bin/cppcheck Cppcheck 2.14.2
-- SQLITECPP_RUN_DOXYGEN OFF
-- SQLITECPP_BUILD_EXAMPLES OFF
-- SQLITECPP_BUILD_TESTS OFF
-- Configuring done (1.2s)
-- Generating done (0.0s)
CMake Warning:
Manually-specified variables were not used by the project:
CMAKE_CXX_FLAGS_DEBUG
CMAKE_C_FLAGS_DEBUG
CMAKE_C_FLAGS_RELEASE
CMAKE_MODULE_LINKER_FLAGS
CMAKE_VERBOSE_MAKEFILE
FETCHCONTENT_FULLY_DISCONNECTED
-- Build files have been written to: /usr/ports/databases/sqlitecpp/work/.build
===> Testing for sqlitecpp-3.3.2
===> sqlitecpp-3.3.2 depends on package: googletest>0 - found
-- Using c++ standard c++11
-- CMake version: 3.29.6
-- Project version: 3.3.2
-- Using Stack Protection hardening
-- CMAKE_CXX_COMPILER '/usr/local/libexec/ccache/c++' 'Clang' '18.1.5'
-- CMAKE_CXX_FLAGS '-O2 -pipe -fstack-protector-strong -fno-strict-aliasing -Wall -Wextra -Wpedantic -Wswitch-enum -Wshadow -Wno-long-long'
-- CMAKE_CXX_FLAGS_RELEASE '-O2 -pipe -fstack-protector-strong -fno-strict-aliasing -DNDEBUG'
-- Link to sqlite3 system library
-- SQLITECPP_RUN_CPPLINT OFF
-- Found Cppcheck: /usr/local/bin/cppcheck Cppcheck 2.14.2
-- SQLITECPP_RUN_DOXYGEN OFF
-- SQLITECPP_BUILD_EXAMPLES OFF
-- Found GTest: /usr/local/lib/cmake/GTest/GTestConfig.cmake (found version "1.15.0")
-- Link to GTest system library
-- Configuring done (0.4s)
-- Generating done (0.0s)
-- Build files have been written to: /usr/ports/databases/sqlitecpp/work/.build
OS: FreeBSD 14.1
Thanks, that's helpful and reassuring. I'll make sure to fix the tests, but I'll want to try to reproduce the issue first
I found out that the error you have is because the sqlite3 library provided by FreeBSD seems to now be compiled with a more strict option;
The SQLITE_DQS compile-time option activates or deactivates the legacy double-quoted string literal misfeature. Legacy behavior is that double-quoted string literals are allowed anywhere.
I could test by changing myself its value from the default to the new value and could reproduce your issue, and then fix it for good.
Now I see this is a very recent change https://www.reddit.com/r/freebsd/comments/1chb82b/sqlite3_pkg_just_became_stricter_with_quoting/?rdt=64491
The default sqlite3 package has the option DQS=off.
After more testing on other OSes, I merged the fix. Thanks for the report!
Thanks for fixing it!
Version: 3.3.2 FreeBSD 14.1