Skip to content

Commit 5313f06

Browse files
committed
Simplify SQLite library checks
These are with minimum required version now considered as always available.
1 parent 8c5e08f commit 5313f06

File tree

2 files changed

+5
-5
lines changed

2 files changed

+5
-5
lines changed

cmake/ext/pdo_sqlite/CMakeLists.txt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -85,8 +85,6 @@ if(TARGET SQLite::SQLite3)
8585
cmake_push_check_state(RESET)
8686
set(CMAKE_REQUIRED_LIBRARIES SQLite::SQLite3)
8787

88-
check_symbol_exists(sqlite3_close_v2 sqlite3.h HAVE_SQLITE3_CLOSE_V2)
89-
9088
check_symbol_exists(
9189
sqlite3_column_table_name
9290
sqlite3.h
@@ -102,6 +100,8 @@ if(TARGET SQLite::SQLite3)
102100
set(PDO_SQLITE_OMIT_LOAD_EXTENSION TRUE)
103101
endif()
104102
cmake_pop_check_state()
103+
104+
set(HAVE_SQLITE3_CLOSE_V2 TRUE)
105105
endif()
106106

107107
################################################################################

cmake/ext/sqlite3/CMakeLists.txt

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -81,9 +81,6 @@ if(TARGET SQLite::SQLite3)
8181
cmake_push_check_state(RESET)
8282
set(CMAKE_REQUIRED_LIBRARIES SQLite::SQLite3)
8383

84-
check_symbol_exists(sqlite3_errstr sqlite3.h HAVE_SQLITE3_ERRSTR)
85-
check_symbol_exists(sqlite3_expanded_sql sqlite3.h HAVE_SQLITE3_EXPANDED_SQL)
86-
8784
check_symbol_exists(
8885
sqlite3_load_extension
8986
sqlite3.h
@@ -93,6 +90,9 @@ if(TARGET SQLite::SQLite3)
9390
set(SQLITE_OMIT_LOAD_EXTENSION TRUE)
9491
endif()
9592
cmake_pop_check_state()
93+
94+
set(HAVE_SQLITE3_ERRSTR TRUE)
95+
set(HAVE_SQLITE3_EXPANDED_SQL TRUE)
9696
endif()
9797

9898
set(HAVE_SQLITE3 TRUE)

0 commit comments

Comments
 (0)