mirror of
https://github.com/cuberite/SQLiteCpp.git
synced 2025-08-05 10:16:01 -04:00
It's the sqlite3 library that needs threads
This commit is contained in:
parent
a25ffb56ab
commit
b1f67393fd
@ -279,13 +279,6 @@ else (SQLITECPP_INTERNAL_SQLITE)
|
|||||||
endif()
|
endif()
|
||||||
endif (SQLITECPP_INTERNAL_SQLITE)
|
endif (SQLITECPP_INTERNAL_SQLITE)
|
||||||
|
|
||||||
# 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
|
# Set includes for target and transitive downstream targets
|
||||||
|
|
||||||
target_include_directories(SQLiteCpp
|
target_include_directories(SQLiteCpp
|
||||||
|
@ -11,6 +11,13 @@ add_library(sqlite3
|
|||||||
sqlite3.h
|
sqlite3.h
|
||||||
)
|
)
|
||||||
|
|
||||||
|
# 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
|
target_include_directories(sqlite3 PUBLIC
|
||||||
$<BUILD_INTERFACE:${CMAKE_CURRENT_SOURCE_DIR}>
|
$<BUILD_INTERFACE:${CMAKE_CURRENT_SOURCE_DIR}>
|
||||||
$<INSTALL_INTERFACE:include/>)
|
$<INSTALL_INTERFACE:include/>)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user