Skip to content

Commit

Permalink
BUILD_SQLITE3为OFF时不链接SQLite3 (#145)
Browse files Browse the repository at this point in the history
  • Loading branch information
SageMik authored Apr 8, 2024
1 parent ffc78ec commit 473fc89
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion src/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,10 @@ else()
target_include_directories(simple INTERFACE ${SQLITE3_HEADERS_DIR})
endif()

target_link_libraries(simple PUBLIC coverage_config PRIVATE PINYIN_TEXT SQLite3)
if(BUILD_SQLITE3)
target_link_libraries(simple PUBLIC coverage_config PRIVATE PINYIN_TEXT SQLite3)
else()
target_link_libraries(simple PUBLIC coverage_config PRIVATE PINYIN_TEXT)
endif()

install(TARGETS simple DESTINATION bin)

0 comments on commit 473fc89

Please sign in to comment.