From: Debian Med Packaging Team Date: Sun, 4 Aug 2024 20:04:32 +0000 (-0400) Subject: fix portability issues that led to Hurd build failures X-Git-Tag: archive/raspbian/2.16.0+ds-7+rpi1~1^2^2~16 X-Git-Url: https://dgit.raspbian.org/?a=commitdiff_plain;h=7f52a977b1ff7353a98090441b71ad76ae8fd37a;p=ncbi-blast%2B.git fix portability issues that led to Hurd build failures * src/build-system/configure(.ac): - Reflect the Hurd's support for -Wl,rpath,... . * src/connect/ncbi_socket_cxx.cpp, src/connect/ext/ncbi_localnet.c: cope with missing PATH_MAX everywhere, not just under Windows. Author: Aaron M. Ucko Last-Update: 2020-09-19 Gbp-Pq: Name hurd_fixes --- diff --git a/c++/src/build-system/configure b/c++/src/build-system/configure index f3d5131a..a2f3f4a2 100755 --- a/c++/src/build-system/configure +++ b/c++/src/build-system/configure @@ -10806,7 +10806,7 @@ if test -z "$CONF_f_runpath" ; then CONF_f_runpath="-R" ;; linux*:[GI]CC | linux*Clang | *bsd*:GCC | *bsd*Clang | cygwin*:GCC \ - | osf*:GCC ) + | osf*:GCC | gnu*:GCC ) CONF_f_runpath="-Wl,-rpath," ;; irix*:* | linux*:KCC | *:Compaq ) diff --git a/c++/src/build-system/configure.ac b/c++/src/build-system/configure.ac index 7f4f962a..9906d512 100644 --- a/c++/src/build-system/configure.ac +++ b/c++/src/build-system/configure.ac @@ -2424,7 +2424,7 @@ if test -z "$CONF_f_runpath" ; then CONF_f_runpath="-R" ;; linux*:[[GI]]CC | linux*Clang | *bsd*:GCC | *bsd*Clang | cygwin*:GCC \ - | osf*:GCC ) + | osf*:GCC | gnu*:GCC ) CONF_f_runpath="-Wl,-rpath," ;; irix*:* | linux*:KCC | *:Compaq ) diff --git a/c++/src/connect/ncbi_localip.c b/c++/src/connect/ncbi_localip.c index f9a79588..a530ffd0 100644 --- a/c++/src/connect/ncbi_localip.c +++ b/c++/src/connect/ncbi_localip.c @@ -67,7 +67,7 @@ # define INADDR_LOOPBACK 0x7F000001 #endif /*!INADDR_LOOPBACK*/ -#if defined(NCBI_OS_MSWIN) && !defined(PATH_MAX) +#if /* defined(NCBI_OS_MSWIN) && */ !defined(PATH_MAX) # ifdef _MAX_PATH # define PATH_MAX _MAX_PATH #else diff --git a/c++/src/connect/ncbi_socket_cxx.cpp b/c++/src/connect/ncbi_socket_cxx.cpp index 9b658656..b1d7ce9e 100644 --- a/c++/src/connect/ncbi_socket_cxx.cpp +++ b/c++/src/connect/ncbi_socket_cxx.cpp @@ -35,7 +35,7 @@ #include "ncbi_assert.h" // no _ASSERT()s, keep clean from xncbi #include #include // for PATH_MAX -#if defined(NCBI_OS_MSWIN) && !defined(PATH_MAX) +#ifndef PATH_MAX # define PATH_MAX 512 // will actually use less than 32 chars #endif // NCBI_OS_MSWIN && !PATH_MAX