diff --git a/CMakeLists.txt b/CMakeLists.txt index ab2034d..2f41a98 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -348,13 +348,6 @@ if (SQLITECPP_DISABLE_EXPANDED_SQL) target_compile_definitions(SQLiteCpp PUBLIC SQLITECPP_DISABLE_EXPANDED_SQL) endif (SQLITECPP_DISABLE_EXPANDED_SQL) -# Link target with pthread and dl for Unix -if (UNIX) - set(THREADS_PREFER_PTHREAD_FLAG ON) - find_package(Threads REQUIRED) - target_link_libraries(SQLiteCpp PUBLIC Threads::Threads ${CMAKE_DL_LIBS}) -endif (UNIX) - # Set includes for target and transitive downstream targets target_include_directories(SQLiteCpp diff --git a/sqlite3/CMakeLists.txt b/sqlite3/CMakeLists.txt index 66a5c8c..dfb5fff 100644 --- a/sqlite3/CMakeLists.txt +++ b/sqlite3/CMakeLists.txt @@ -24,6 +24,18 @@ target_include_directories(sqlite3 $ $) +# Link target with pthread and dl for Unix +if (UNIX) + set(THREADS_PREFER_PTHREAD_FLAG ON) + find_package(Threads REQUIRED) + target_link_libraries(sqlite3 PUBLIC Threads::Threads ${CMAKE_DL_LIBS}) +endif (UNIX) + +target_include_directories(sqlite3 PUBLIC + $ + $) + + if (SQLITE_ENABLE_COLUMN_METADATA) # Enable the use of SQLite column metadata method # Require that the sqlite3 library is also compiled with this flag: