diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 097156908..c8fd43100 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -97,7 +97,15 @@ jobs: CXX: clang++ libdir: lib - - name: Rocky Linux x64 Clang gnustep-2.2 + - name: Rocky Linux 8 x64 Clang gnustep-2.2 + container: rockylinux:8 + library-combo: ng-gnu-gnu + runtime-version: gnustep-2.2 + CC: clang + CXX: clang++ + libdir: lib64 + + - name: Rocky Linux 9 x64 Clang gnustep-2.2 container: rockylinux:9 library-combo: ng-gnu-gnu runtime-version: gnustep-2.2 diff --git a/Headers/GNUstepBase/config.h.in b/Headers/GNUstepBase/config.h.in index cee5baaac..08fdcb905 100644 --- a/Headers/GNUstepBase/config.h.in +++ b/Headers/GNUstepBase/config.h.in @@ -397,9 +397,6 @@ /* Define to 1 if you have the `m' library (-lm). */ #undef HAVE_LIBM -/* Define to 1 if you have the `resolv' library (-lresolv). */ -#undef HAVE_LIBRESOLV - /* Define to 1 if you have the `rt' library (-lrt). */ #undef HAVE_LIBRT diff --git a/Source/NSURLSessionConfiguration.m b/Source/NSURLSessionConfiguration.m index 2f4172207..856dd87c1 100644 --- a/Source/NSURLSessionConfiguration.m +++ b/Source/NSURLSessionConfiguration.m @@ -27,9 +27,12 @@ * Software Foundation, Inc., 31 Milk Street #960789 Boston, MA 02196 USA. */ +#import "Foundation/NSException.h" #import "Foundation/NSURLSession.h" #import "Foundation/NSHTTPCookie.h" +#include + // TODO: This is the old implementation. It requires a rewrite! @implementation NSURLSessionConfiguration @@ -166,7 +169,14 @@ - (NSInteger) HTTPMaximumConnectionLifetime - (void) setHTTPMaximumConnectionLifetime: (NSInteger)n { +#if CURL_AT_LEAST_VERSION(7, 66, 0) _HTTPMaximumConnectionLifetime = n; +#else + [NSException raise: NSInternalInconsistencyException + format: @"-[%@ %@] not supported by the version of Curl" + @" this library was built with", + NSStringFromClass([self class]), NSStringFromSelector(_cmd)]; +#endif } - (BOOL) HTTPShouldUsePipelining diff --git a/Source/NSURLSessionTask.m b/Source/NSURLSessionTask.m index 0f0ccef62..820b2b287 100644 --- a/Source/NSURLSessionTask.m +++ b/Source/NSURLSessionTask.m @@ -174,7 +174,9 @@ @interface _GSMutableInsensitiveDictionary : NSMutableDictionary case CURLE_COULDNT_RESOLVE_HOST: urlError = NSURLErrorDNSLookupFailed; break; +#if CURL_AT_LEAST_VERSION(7, 69, 0) case CURLE_QUIC_CONNECT_ERROR: +#endif case CURLE_COULDNT_CONNECT: urlError = NSURLErrorCannotConnectToHost; break; @@ -1048,10 +1050,12 @@ - (instancetype) initWithSession: (NSURLSession *)session /* Set to HTTP/3 if requested */ if ([request assumesHTTP3Capable]) { +#if CURL_AT_LEAST_VERSION(7, 66, 0) curl_easy_setopt( _easyHandle, CURLOPT_HTTP_VERSION, CURL_HTTP_VERSION_3); +#endif } /* Configure the custom CA certificate if available */ diff --git a/configure b/configure index 31b6aa82a..8a3a877fc 100755 --- a/configure +++ b/configure @@ -14686,9 +14686,9 @@ if eval $CURL_CONFIG --version 2>/dev/null >/dev/null && test "$SKIP_CURL_CONFIG curl_ver=`$CURL_CONFIG --version | sed -e "s/libcurl //g"` curl_maj=`echo $curl_ver | sed -e "s/^\(.*\)\.\(.*\)\.\(.*\)$/\1/"` curl_min=`echo $curl_ver | sed -e "s/^\(.*\)\.\(.*\)\.\(.*\)$/\2/"` - if test $curl_maj -lt 7 -o \( $curl_maj -eq 7 -a $curl_min -lt 66 \); then - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: FAILED (version too old to use" >&5 -printf "%s\n" "FAILED (version too old to use" >&6; } + if test $curl_maj -lt 7 -o \( $curl_maj -eq 7 -a $curl_min -lt 61 \); then + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: FAILED (version $curl_ver too old to use, need at least 7.61)" >&5 +printf "%s\n" "FAILED (version $curl_ver too old to use, need at least 7.61)" >&6; } else { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes ... version $curl_ver" >&5 printf "%s\n" "yes ... version $curl_ver" >&6; } @@ -14718,7 +14718,7 @@ else if pkg-config --exists libcurl; then { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes ... via pkg-config" >&5 printf "%s\n" "yes ... via pkg-config" >&6; } - if $PKG_CONFIG --atleast-version 2.66.0 libcurl; then + if $PKG_CONFIG --atleast-version 7.61.0 libcurl; then for ac_header in curl/curl.h do : ac_fn_c_check_header_compile "$LINENO" "curl/curl.h" "ac_cv_header_curl_curl_h" "$ac_includes_default" @@ -14740,8 +14740,8 @@ done curl_all=yes fi else - { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: FAILED (version too old to use" >&5 -printf "%s\n" "FAILED (version too old to use" >&6; } + { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: FAILED (version too old to use, need at least 7.61)" >&5 +printf "%s\n" "FAILED (version too old to use, need at least 7.61)" >&6; } curl_all=no fi else diff --git a/configure.ac b/configure.ac index fdb3c19da..b00758d31 100644 --- a/configure.ac +++ b/configure.ac @@ -3757,8 +3757,8 @@ if eval $CURL_CONFIG --version 2>/dev/null >/dev/null && test "$SKIP_CURL_CONFIG curl_ver=`$CURL_CONFIG --version | sed -e "s/libcurl //g"` curl_maj=`echo $curl_ver | sed -e "s/^\(.*\)\.\(.*\)\.\(.*\)$/\1/"` curl_min=`echo $curl_ver | sed -e "s/^\(.*\)\.\(.*\)\.\(.*\)$/\2/"` - if test $curl_maj -lt 7 -o \( $curl_maj -eq 7 -a $curl_min -lt 66 \); then - AC_MSG_RESULT([FAILED (version too old to use]) + if test $curl_maj -lt 7 -o \( $curl_maj -eq 7 -a $curl_min -lt 61 \); then + AC_MSG_RESULT([FAILED (version $curl_ver too old to use, need at least 7.61)]) else AC_MSG_RESULT(yes ... version $curl_ver) AC_CHECK_HEADERS(curl/curl.h, curl_ok=yes, curl_ok=no) @@ -3775,7 +3775,7 @@ else if test -n "$PKG_CONFIG"; then if pkg-config --exists libcurl; then AC_MSG_RESULT(yes ... via pkg-config) - if $PKG_CONFIG --atleast-version 2.66.0 libcurl; then + if $PKG_CONFIG --atleast-version 7.61.0 libcurl; then AC_CHECK_HEADERS(curl/curl.h, curl_ok=yes, curl_ok=no) if test "$curl_ok" = yes; then HAVE_LIBCURL=1 @@ -3786,7 +3786,7 @@ else curl_all=yes fi else - AC_MSG_RESULT([FAILED (version too old to use]) + AC_MSG_RESULT([FAILED (version too old to use, need at least 7.61)]) curl_all=no fi else