mirror of
https://github.com/microsoft/vcpkg.git
synced 2024-11-24 04:19:08 +08:00
[libpq] Fix MinGW build (#34747)
This commit is contained in:
parent
4b00fb593f
commit
cbb9d90a2e
@ -24,7 +24,6 @@ vcpkg_extract_source_archive(
|
||||
file(GLOB _py3_include_path "${CURRENT_HOST_INSTALLED_DIR}/include/python3*")
|
||||
string(REGEX MATCH "python3\\.([0-9]+)" _python_version_tmp "${_py3_include_path}")
|
||||
set(PYTHON_VERSION_MINOR "${CMAKE_MATCH_1}")
|
||||
vcpkg_replace_string("${SOURCE_PATH}/configure.ac" "python_version=3.REPLACEME" "python_version=3.${PYTHON_VERSION_MINOR}")
|
||||
|
||||
if("client" IN_LIST FEATURES)
|
||||
set(HAS_TOOLS TRUE)
|
||||
@ -89,7 +88,7 @@ else()
|
||||
file(COPY "${CMAKE_CURRENT_LIST_DIR}/Makefile" DESTINATION "${SOURCE_PATH}")
|
||||
|
||||
vcpkg_list(SET BUILD_OPTS)
|
||||
foreach(option IN ITEMS icu lz4 nls openssl python readline xml xslt zlib zstd)
|
||||
foreach(option IN ITEMS icu lz4 nls openssl readline xml xslt zlib zstd)
|
||||
if(option IN_LIST FEATURES)
|
||||
list(APPEND BUILD_OPTS --with-${option})
|
||||
else()
|
||||
@ -103,6 +102,7 @@ else()
|
||||
endif()
|
||||
endif()
|
||||
if("python" IN_LIST FEATURES)
|
||||
list(APPEND BUILD_OPTS --with-python=3.${PYTHON_VERSION_MINOR})
|
||||
vcpkg_find_acquire_program(PYTHON3)
|
||||
list(APPEND BUILD_OPTS "PYTHON=${PYTHON3}")
|
||||
endif()
|
||||
|
@ -1,14 +1,24 @@
|
||||
diff --git a/configure.ac b/configure.ac
|
||||
index a35395e..3c1b3e2 100644
|
||||
index 7f97248992..33b6c84fc4 100644
|
||||
--- a/configure.ac
|
||||
+++ b/configure.ac
|
||||
@@ -1176,7 +1176,19 @@ fi
|
||||
@@ -891,7 +891,9 @@ AC_SUBST(with_perl)
|
||||
# Optionally build Python modules (PL/Python)
|
||||
#
|
||||
AC_MSG_CHECKING([whether to build Python modules])
|
||||
-PGAC_ARG_BOOL(with, python, no, [build Python modules (PL/Python)])
|
||||
+PGAC_ARG_OPTARG(with, python, [PYTHON_VERSION], [build Python modules (PL/Python)],
|
||||
+ [],
|
||||
+ [python_version=$withval])
|
||||
AC_MSG_RESULT([$with_python])
|
||||
AC_SUBST(with_python)
|
||||
|
||||
@@ -1214,7 +1216,18 @@ fi
|
||||
|
||||
if test "$with_python" = yes; then
|
||||
PGAC_PATH_PYTHON
|
||||
- PGAC_CHECK_PYTHON_EMBED_SETUP
|
||||
+ python_majorversion=3
|
||||
+ python_version=3.REPLACEME
|
||||
+ PKG_CHECK_MODULES(PYTHON_EMBED, python-${python_version}-embed)
|
||||
+ python_includespec="${PYTHON_EMBED_CFLAGS}"
|
||||
+ python_libdir=[$(echo " ${PYTHON_EMBED_LIBS}" | sed -e 's/\( -L[^ ]*\).*/\1/' -e 's/^.* -L//')]
|
||||
|
@ -1,6 +1,7 @@
|
||||
{
|
||||
"name": "libpq",
|
||||
"version": "16.0",
|
||||
"port-version": 1,
|
||||
"description": "The official database access API of postgresql",
|
||||
"homepage": "https://www.postgresql.org/",
|
||||
"license": "PostgreSQL",
|
||||
|
@ -4590,7 +4590,7 @@
|
||||
},
|
||||
"libpq": {
|
||||
"baseline": "16.0",
|
||||
"port-version": 0
|
||||
"port-version": 1
|
||||
},
|
||||
"libpqxx": {
|
||||
"baseline": "7.8.1",
|
||||
|
@ -1,5 +1,10 @@
|
||||
{
|
||||
"versions": [
|
||||
{
|
||||
"git-tree": "1f0007ec87e337d4f484164ecf589395b174d044",
|
||||
"version": "16.0",
|
||||
"port-version": 1
|
||||
},
|
||||
{
|
||||
"git-tree": "cbd6314cbfd04132985a7a6412184d368c3cd0b6",
|
||||
"version": "16.0",
|
||||
|
Loading…
Reference in New Issue
Block a user