From: Viktor Szakats Date: Fri, 2 Jan 2026 16:45:09 +0000 (+0100) Subject: GHA: disable autotools static libcurl in many jobs X-Git-Tag: curl-8_18_0~32 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=d057b705fdb44b2df99ce6fc6ffb8f2a3530755a;p=thirdparty%2Fcurl.git GHA: disable autotools static libcurl in many jobs To avoid building libcurl in both static and shared flavor by default. It results in 1.5-2.x speed-up for the curl build step in most jobs. Saving a total of 6-7 minutes. In the Cygwin job alone it saves 1-1.5m. Also: - enable static + shared in a Windows job to keep testing this combo. Follow-up to ff958fc4b2c606d70de8dbfe083bee98896c0072 #20159 Closes #20167 --- diff --git a/.github/workflows/http3-linux.yml b/.github/workflows/http3-linux.yml index 5f85a51be7..14b2e457c0 100644 --- a/.github/workflows/http3-linux.yml +++ b/.github/workflows/http3-linux.yml @@ -664,7 +664,7 @@ jobs: -DHTTPD_NGHTTPX=/home/runner/nghttp2/build/bin/nghttpx \ ${MATRIX_GENERATE} else - mkdir bld && cd bld && ../configure --enable-warnings --enable-werror --enable-debug \ + mkdir bld && cd bld && ../configure --enable-warnings --enable-werror --enable-debug --disable-static \ --with-libuv \ --with-test-nghttpx=/home/runner/nghttp2/build/bin/nghttpx \ --disable-dependency-tracking --enable-option-checking=fatal \ diff --git a/.github/workflows/linux-old.yml b/.github/workflows/linux-old.yml index 04e01d9083..75dd407b04 100644 --- a/.github/workflows/linux-old.yml +++ b/.github/workflows/linux-old.yml @@ -162,7 +162,7 @@ jobs: run: | mkdir bld-am cd bld-am - ../configure --disable-dependency-tracking --enable-unity --enable-warnings --enable-werror \ + ../configure --disable-dependency-tracking --enable-unity --enable-warnings --enable-werror --disable-shared \ --without-ssl --enable-ares --without-libssh2 --with-zstd --with-gssapi --with-librtmp \ --prefix="$PWD"/../curl-install-am diff --git a/.github/workflows/linux.yml b/.github/workflows/linux.yml index 21ae0b2c0b..8ba8ab1237 100644 --- a/.github/workflows/linux.yml +++ b/.github/workflows/linux.yml @@ -206,7 +206,7 @@ jobs: - name: 'openssl clang krb5 openldap static' install_steps: openldap-static install_packages: libidn2-dev libkrb5-dev clang libssl-dev - configure: CC=clang --disable-shared --with-openssl --with-gssapi --enable-debug --disable-docs --disable-manual --with-ldap=/home/runner/openldap-static --with-ldap-lib=ldap --with-lber-lib=lber + configure: CC=clang --enable-static --disable-shared --with-openssl --with-gssapi --enable-debug --disable-docs --disable-manual --with-ldap=/home/runner/openldap-static --with-ldap-lib=ldap --with-lber-lib=lber - name: 'openssl clang krb5 LTO' install_packages: libssh2-1-dev libkrb5-dev clang @@ -343,12 +343,12 @@ jobs: - name: 'event-based' install_packages: libssh-dev - configure: --enable-debug --disable-shared --disable-threaded-resolver --with-libssh --with-openssl + configure: --enable-debug --enable-static --disable-shared --disable-threaded-resolver --with-libssh --with-openssl tflags: '-n --test-event --min=1350' - name: 'duphandle' install_packages: libssh-dev - configure: --enable-debug --disable-shared --disable-threaded-resolver --with-libssh --with-openssl + configure: --enable-debug --enable-static --disable-shared --disable-threaded-resolver --with-libssh --with-openssl tflags: '-n --test-duphandle' - name: 'rustls valgrind 1' @@ -376,7 +376,7 @@ jobs: - name: 'Slackware !ssl gssapi gcc' # Flags used to build the curl Slackware package, except OpenSSL 1.1.0: # https://ftpmirror.infania.net/slackware/slackware64-current/source/n/curl/curl.SlackBuild - configure: --enable-debug --without-ssl --with-libssh2 --with-gssapi --enable-ares --enable-static=no --without-ca-bundle --with-ca-path=/etc/ssl/certs + configure: --enable-debug --without-ssl --with-libssh2 --with-gssapi --enable-ares --without-ca-bundle --with-ca-path=/etc/ssl/certs # Docker Hub image that `container-job` executes in container: 'andy5995/slackware-build-essential:15.0' @@ -737,7 +737,7 @@ jobs: else mkdir bld && cd bld && \ ${MATRIX_CONFIGURE_PREFIX} \ - ../configure --prefix="$HOME"/curl-install --enable-unity --enable-warnings --enable-werror \ + ../configure --prefix="$HOME"/curl-install --enable-unity --enable-warnings --enable-werror --disable-static \ --disable-dependency-tracking --enable-option-checking=fatal \ ${MATRIX_CONFIGURE} fi diff --git a/.github/workflows/macos.yml b/.github/workflows/macos.yml index be61c4d312..ca1a742269 100644 --- a/.github/workflows/macos.yml +++ b/.github/workflows/macos.yml @@ -259,7 +259,7 @@ jobs: --enable-debug --disable-alt-svc --disable-dict --disable-file --disable-ftp --disable-gopher --disable-imap --disable-ldap --disable-pop3 --without-librtmp --disable-rtsp - --disable-shared --disable-smb --disable-smtp --disable-telnet --disable-tftp --disable-unix-sockets + --enable-static --disable-shared --disable-smb --disable-smtp --disable-telnet --disable-tftp --disable-unix-sockets --without-brotli --without-gssapi --without-libidn2 --without-libpsl --without-librtmp --without-libssh2 --without-libssh --without-nghttp2 --disable-ntlm --without-ssl --without-zlib --without-zstd @@ -447,7 +447,7 @@ jobs: fi [ -n "${MATRIX_MACOS_VERSION_MIN}" ] && CFLAGS+=" -mmacosx-version-min=${MATRIX_MACOS_VERSION_MIN}" [[ "${MATRIX_INSTALL_STEPS}" = *'pytest'* ]] && options+=' --with-test-vsftpd=no' # Skip ~20 tests that stretch run time by 7x on macOS - mkdir bld && cd bld && ../configure --prefix="$PWD"/curl-install --enable-unity --enable-warnings --enable-werror \ + mkdir bld && cd bld && ../configure --prefix="$PWD"/curl-install --enable-unity --enable-warnings --enable-werror --disable-static \ --disable-dependency-tracking --enable-option-checking=fatal \ --with-libpsl=/opt/homebrew/opt/libpsl \ ${MATRIX_CONFIGURE} ${options} @@ -667,7 +667,7 @@ jobs: fi [ -n "${MATRIX_MACOS_VERSION_MIN}" ] && CFLAGS+=" -mmacosx-version-min=${MATRIX_MACOS_VERSION_MIN}" # would pick up nghttp2, libidn2, but libssh2 is disabled by default - mkdir bld && cd bld && ../configure --enable-unity --enable-warnings --enable-werror \ + mkdir bld && cd bld && ../configure --enable-unity --enable-warnings --enable-werror --disable-static \ --disable-dependency-tracking --enable-option-checking=fatal \ --disable-docs --disable-manual \ --with-openssl="$(brew --prefix openssl)" \ diff --git a/.github/workflows/non-native.yml b/.github/workflows/non-native.yml index 36e87bcbf9..882ff5484f 100644 --- a/.github/workflows/non-native.yml +++ b/.github/workflows/non-native.yml @@ -190,7 +190,7 @@ jobs: options='--disable-manual --disable-docs' # Slow with autotools, skip on emulated CPU fi mkdir bld && cd bld - time ../configure --enable-unity --enable-debug --enable-warnings --enable-werror \ + time ../configure --enable-unity --enable-debug --enable-warnings --enable-werror --disable-static \ --prefix="$HOME"/curl-install \ --with-openssl \ --with-brotli --enable-ldap --enable-ldaps --with-libidn2 --with-libssh2 --with-nghttp2 --with-gssapi \ @@ -286,7 +286,7 @@ jobs: ${MATRIX_OPTIONS} else TOOLCHAIN="${ANDROID_NDK_HOME}/toolchains/llvm/prebuilt/linux-x86_64" - mkdir bld && cd bld && ../configure --disable-dependency-tracking --enable-option-checking=fatal --enable-unity --enable-warnings --enable-werror \ + mkdir bld && cd bld && ../configure --disable-dependency-tracking --enable-option-checking=fatal --enable-unity --enable-warnings --enable-werror --disable-shared \ CC="$TOOLCHAIN/bin/aarch64-linux-android${MATRIX_PLATFORM}-clang" \ AR="$TOOLCHAIN/bin/llvm-ar" \ RANLIB="$TOOLCHAIN/bin/llvm-ranlib" \ diff --git a/.github/workflows/windows.yml b/.github/workflows/windows.yml index d7c2bcd8ce..d3485eb90b 100644 --- a/.github/workflows/windows.yml +++ b/.github/workflows/windows.yml @@ -99,7 +99,7 @@ jobs: -DCURL_WERROR=ON \ ${MATRIX_CONFIG} else - mkdir bld && cd bld && ../configure --enable-unity --enable-warnings --enable-werror \ + mkdir bld && cd bld && ../configure --enable-unity --enable-warnings --enable-werror --disable-static \ --prefix="$HOME"/curl-install \ --with-libssh2 \ --disable-dependency-tracking --enable-option-checking=fatal \ @@ -203,8 +203,8 @@ jobs: - { build: 'cmake' , sys: 'msys' , env: 'x86_64' , tflags: '' , config: '-DENABLE_DEBUG=ON -DENABLE_THREADED_RESOLVER=OFF', install: 'openssl-devel libssh2-devel', name: 'default' } - { build: 'autotools', sys: 'msys' , env: 'x86_64' , tflags: '' , config: '--with-openssl', install: 'openssl-devel libssh2-devel', name: 'default R' } # MinGW - - { build: 'autotools', sys: 'mingw64' , env: 'x86_64' , tflags: 'skiprun' , config: '--enable-debug --with-openssl --disable-threaded-resolver --disable-curldebug --enable-static=no --without-zlib CPPFLAGS=-D_WIN32_WINNT=0x0501', install: 'mingw-w64-x86_64-openssl mingw-w64-x86_64-libssh2', name: 'default XP' } - - { build: 'autotools', sys: 'mingw64' , env: 'x86_64' , tflags: '' , config: '--enable-debug --with-openssl --enable-windows-unicode --enable-ares --with-openssl-quic --enable-shared=no', install: 'mingw-w64-x86_64-c-ares mingw-w64-x86_64-openssl mingw-w64-x86_64-nghttp3 mingw-w64-x86_64-libssh2', name: 'c-ares U' } + - { build: 'autotools', sys: 'mingw64' , env: 'x86_64' , tflags: 'skiprun' , config: '--enable-debug --with-openssl --disable-threaded-resolver --disable-curldebug --enable-static --without-zlib CPPFLAGS=-D_WIN32_WINNT=0x0501', install: 'mingw-w64-x86_64-openssl mingw-w64-x86_64-libssh2', name: 'default XP' } + - { build: 'autotools', sys: 'mingw64' , env: 'x86_64' , tflags: '' , config: '--enable-debug --with-openssl --enable-windows-unicode --enable-ares --with-openssl-quic --enable-static --disable-shared', install: 'mingw-w64-x86_64-c-ares mingw-w64-x86_64-openssl mingw-w64-x86_64-nghttp3 mingw-w64-x86_64-libssh2', name: 'c-ares U' } - { build: 'cmake' , sys: 'mingw64' , env: 'x86_64' , tflags: '--min=1650', config: '-DENABLE_DEBUG=ON -DBUILD_SHARED_LIBS=OFF -DCURL_USE_SCHANNEL=ON -DENABLE_UNICODE=ON -DENABLE_ARES=ON', install: 'mingw-w64-x86_64-c-ares mingw-w64-x86_64-libssh2', type: 'Debug', name: 'schannel c-ares U' } # MinGW torture - { build: 'cmake' , sys: 'mingw64' , env: 'x86_64' , tflags: '-t --shallow=13 --min=700 1 to 950' , config: '-DENABLE_DEBUG=ON -DBUILD_SHARED_LIBS=OFF -DCURL_USE_SCHANNEL=ON -DENABLE_UNICODE=ON -DENABLE_ARES=ON', install: 'mingw-w64-x86_64-c-ares mingw-w64-x86_64-libssh2', type: 'Debug', name: 'schannel U torture 1' } @@ -217,7 +217,7 @@ jobs: - { build: 'cmake' , sys: 'clangarm64', env: 'clang-aarch64', tflags: 'skiprun' , config: '-DENABLE_DEBUG=OFF -DBUILD_SHARED_LIBS=ON -DCURL_USE_SCHANNEL=ON -DENABLE_UNICODE=ON -DENABLE_CURLDEBUG=ON', install: 'mingw-w64-clang-aarch64-libssh2', type: 'Release', name: 'schannel R TrackMemory', image: 'windows-11-arm' } - { build: 'cmake' , sys: 'clang64' , env: 'clang-x86_64' , tflags: 'skiprun' , config: '-DENABLE_DEBUG=ON -DBUILD_SHARED_LIBS=OFF -DCURL_USE_OPENSSL=ON -DENABLE_UNICODE=OFF -DUSE_NGTCP2=ON', install: 'mingw-w64-clang-x86_64-openssl mingw-w64-clang-x86_64-nghttp3 mingw-w64-clang-x86_64-ngtcp2 mingw-w64-clang-x86_64-libssh2', type: 'Release', name: 'openssl', chkprefill: '_chkprefill' } - { build: 'cmake' , sys: 'ucrt64' , env: 'ucrt-x86_64' , tflags: 'skiprun' , config: '-DENABLE_DEBUG=OFF -DBUILD_SHARED_LIBS=ON -DCURL_USE_OPENSSL=ON', install: 'mingw-w64-ucrt-x86_64-openssl mingw-w64-ucrt-x86_64-libssh2', type: 'Release', test: 'uwp', name: 'schannel' } - # { build: 'autotools', sys: 'ucrt64' , env: 'ucrt-x86_64' , tflags: 'skiprun' , config: '--without-debug --with-schannel --enable-shared', install: 'mingw-w64-ucrt-x86_64-libssh2', type: 'Release', test: 'uwp', name: 'schannel' } + # { build: 'autotools', sys: 'ucrt64' , env: 'ucrt-x86_64' , tflags: 'skiprun' , config: '--without-debug --with-schannel --disable-static', install: 'mingw-w64-ucrt-x86_64-libssh2', type: 'Release', test: 'uwp', name: 'schannel' } - { build: 'cmake' , sys: 'mingw64' , env: 'x86_64' , tflags: 'skiprun' , config: '-DENABLE_DEBUG=ON -DBUILD_SHARED_LIBS=ON -DCURL_USE_SCHANNEL=ON -DENABLE_UNICODE=ON -DCMAKE_VERBOSE_MAKEFILE=ON', install: 'mingw-w64-x86_64-libssh2', type: 'Debug', cflags: '-DCURL_SCHANNEL_DEV_DEBUG', name: 'schannel dev debug', image: 'windows-2025' } - { build: 'cmake' , sys: 'mingw32' , env: 'i686' , tflags: 'skiprun' , config: '-DENABLE_DEBUG=OFF -DBUILD_SHARED_LIBS=ON -DCURL_USE_SCHANNEL=ON -DENABLE_UNICODE=ON', install: 'mingw-w64-i686-libssh2', type: 'Release', name: 'schannel R' } fail-fast: false @@ -302,7 +302,7 @@ jobs: fi else export CFLAGS CPPFLAGS - mkdir bld && cd bld && ../configure --enable-unity --enable-warnings --enable-werror \ + mkdir bld && cd bld && ../configure --enable-unity --enable-warnings --enable-werror --disable-static \ --prefix="$HOME"/curl-install \ --with-libssh2 \ --disable-dependency-tracking --enable-option-checking=fatal \ @@ -648,7 +648,7 @@ jobs: -D_CURL_SKIP_BUILD_CERTS=ON \ ${options} else - mkdir bld && cd bld && ../configure --enable-unity --enable-warnings --enable-werror \ + mkdir bld && cd bld && ../configure --enable-unity --enable-warnings --enable-werror --disable-static \ --host="${TRIPLET}" \ --with-schannel --with-winidn \ --without-libpsl \