Skip to content

Commit

Permalink
Always build as if cross compiling
Browse files Browse the repository at this point in the history
  • Loading branch information
dg0yt committed May 8, 2023
1 parent e7700f7 commit a4e83a5
Show file tree
Hide file tree
Showing 5 changed files with 15 additions and 12 deletions.
15 changes: 8 additions & 7 deletions ports/libpq/patches/fix-configure.patch
Original file line number Diff line number Diff line change
@@ -1,17 +1,18 @@
diff --git a/configure.ac b/configure.ac
index fba79ee..4fadb94 100644
index 9a73f50..a35395e 100644
--- a/configure.ac
+++ b/configure.ac
@@ -19,7 +19,7 @@ m4_pattern_forbid(^PGAC_)dnl to catch undefined macros
@@ -19,7 +19,8 @@ m4_pattern_forbid(^PGAC_)dnl to catch undefined macros

AC_INIT([PostgreSQL], [15.2], [[email protected]], [], [https://www.postgresql.org/])

-m4_if(m4_defn([m4_PACKAGE_VERSION]), [2.69], [], [m4_fatal([Autoconf version 2.69 is required.
+cross_compiling=yes # Avoid conftest loading shared objects
+m4_if(m4_defn([m4_PACKAGE_VERSION]), [2.69], [], [m4_warn([unsupported],[Autoconf version 2.69 is required.
Untested combinations of 'autoconf' and PostgreSQL versions are not
recommended. You can remove the check from 'configure.ac' but it is then
your responsibility whether the result works or not.])])
@@ -1184,7 +1184,8 @@ if test "$enable_thread_safety" = yes; then
@@ -1274,7 +1275,8 @@ if test "$enable_thread_safety" = yes; then
fi

if test "$with_readline" = yes; then
Expand All @@ -21,7 +22,7 @@ index fba79ee..4fadb94 100644
if test x"$pgac_cv_check_readline" = x"no"; then
AC_MSG_ERROR([readline library not found
If you have readline already installed, see config.log for details on the
@@ -1194,7 +1195,7 @@ Use --without-readline to disable readline support.])
@@ -1284,7 +1286,7 @@ Use --without-readline to disable readline support.])
fi

if test "$with_zlib" = yes; then
Expand All @@ -30,7 +31,7 @@ index fba79ee..4fadb94 100644
[AC_MSG_ERROR([zlib library not found
If you have zlib already installed, see config.log for details on the
failure. It is possible the compiler isn't looking in the proper directory.
@@ -1243,6 +1244,9 @@ if test "$with_ssl" = openssl ; then
@@ -1333,6 +1335,9 @@ if test "$with_ssl" = openssl ; then
# Minimum required OpenSSL version is 1.0.1
AC_DEFINE(OPENSSL_API_COMPAT, [0x10001000L],
[Define to the OpenSSL API version in use. This avoids deprecation warnings from newer OpenSSL versions.])
Expand All @@ -40,15 +41,15 @@ index fba79ee..4fadb94 100644
if test "$PORTNAME" != "win32"; then
AC_CHECK_LIB(crypto, CRYPTO_new_ex_data, [], [AC_MSG_ERROR([library 'crypto' is required for OpenSSL])])
AC_CHECK_LIB(ssl, SSL_new, [], [AC_MSG_ERROR([library 'ssl' is required for OpenSSL])])
@@ -1250,6 +1254,7 @@ if test "$with_ssl" = openssl ; then
@@ -1340,6 +1345,7 @@ if test "$with_ssl" = openssl ; then
AC_SEARCH_LIBS(CRYPTO_new_ex_data, [eay32 crypto], [], [AC_MSG_ERROR([library 'eay32' or 'crypto' is required for OpenSSL])])
AC_SEARCH_LIBS(SSL_new, [ssleay32 ssl], [], [AC_MSG_ERROR([library 'ssleay32' or 'ssl' is required for OpenSSL])])
fi
+ fi
# Function introduced in OpenSSL 1.0.2.
AC_CHECK_FUNCS([X509_get_signature_nid])
# Functions introduced in OpenSSL 1.1.0. We used to check for
@@ -1365,15 +1365,18 @@ if test "$with_pam" = yes ; then
@@ -1363,19 +1369,23 @@ if test "$with_pam" = yes ; then
fi

if test "$with_libxml" = yes ; then
Expand Down
3 changes: 0 additions & 3 deletions ports/libpq/portfile.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -315,11 +315,8 @@ else()
7550b843964744607f736a7138f10c6cd92489406a1b84ac71d9a9d8aa16bc69048aa1b24e1f49291b010347047008194c334ca9c632e17fa8245e85549e3c7a
OPTIONS
${BUILD_OPTS}
OPTIONS_RELEASE
"DYLD_FALLBACK_LIBRARY_PATH=${CURRENT_INSTALLED_DIR}/lib:${CURRENT_INSTALLED_DIR}/debug/lib"
OPTIONS_DEBUG
--enable-debug
"DYLD_FALLBACK_LIBRARY_PATH=${CURRENT_INSTALLED_DIR}/debug/lib:${CURRENT_INSTALLED_DIR}/lib"
)

if(VCPKG_LIBRARY_LINKAGE STREQUAL "dynamic")
Expand Down
2 changes: 1 addition & 1 deletion scripts/ports.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -147,7 +147,7 @@ if(CMD STREQUAL "BUILD")
include("${CURRENT_PORT_DIR}/portfile.cmake")
if(DEFINED PORT)
if(VCPKG_FIXUP_ELF_RPATH)
include("${SCRIPTS}/cmake/z_vcpkg_fixup_rpath.cmake")
#include("${SCRIPTS}/cmake/z_vcpkg_fixup_rpath.cmake")
endif()
include("${SCRIPTS}/build_info.cmake")
endif()
Expand Down
2 changes: 1 addition & 1 deletion versions/baseline.json
Original file line number Diff line number Diff line change
Expand Up @@ -4386,7 +4386,7 @@
},
"libpq": {
"baseline": "15.2",
"port-version": 3
"port-version": 4
},
"libpqxx": {
"baseline": "7.7.4",
Expand Down
5 changes: 5 additions & 0 deletions versions/l-/libpq.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,10 @@
{
"versions": [
{
"git-tree": "c3335f31812e4623c46d3563f325cedfb2a815c0",
"version": "15.2",
"port-version": 4
},
{
"git-tree": "74cc57fa79744500aef02f0b66be5f46b8005af3",
"version": "15.2",
Expand Down

0 comments on commit a4e83a5

Please sign in to comment.