Skip to content

Commit d675ac3

Browse files
committed
Sync with upstream
- Added check for PQclosePrepared into ext/pgsql
1 parent 98d58d5 commit d675ac3

File tree

3 files changed

+18
-0
lines changed

3 files changed

+18
-0
lines changed

cmake/ext/pgsql/CMakeLists.txt

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -111,5 +111,15 @@ if(TARGET PostgreSQL::PostgreSQL)
111111
""
112112
HAVE_PG_SET_CHUNKED_ROWS_SIZE
113113
)
114+
115+
# Available since PostgreSQL 17.
116+
if(PostgreSQL_VERSION_STRING VERSION_GREATER_EQUAL 17)
117+
check_library_exists(
118+
PostgreSQL::PostgreSQL
119+
PQclosePrepared
120+
""
121+
HAVE_PG_CLOSE_STMT
122+
)
123+
endif()
114124
endif()
115125
endif()

cmake/main/config.w32.cmake.h.in

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1112,6 +1112,10 @@
11121112
later). */
11131113
#cmakedefine HAVE_PG_CHANGE_PASSWORD 1
11141114

1115+
/* Define to 1 if libpq has the 'PQclosePrepared' function (PostgreSQL 17 or
1116+
later). */
1117+
#cmakedefine HAVE_PG_CLOSE_STMT 1
1118+
11151119
/* Define to 1 if libpq has the 'PQresultMemorySize' function (PostgreSQL 12
11161120
or later). */
11171121
#cmakedefine HAVE_PG_RESULT_MEMORY_SIZE 1

cmake/main/php_config.cmake.h.in

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1106,6 +1106,10 @@
11061106
later). */
11071107
#cmakedefine HAVE_PG_CHANGE_PASSWORD 1
11081108

1109+
/* Define to 1 if libpq has the 'PQclosePrepared' function (PostgreSQL 17 or
1110+
later). */
1111+
#cmakedefine HAVE_PG_CLOSE_STMT 1
1112+
11091113
/* Define to 1 if libpq has the 'PQresultMemorySize' function (PostgreSQL 12
11101114
or later). */
11111115
#cmakedefine HAVE_PG_RESULT_MEMORY_SIZE 1

0 commit comments

Comments
 (0)