1# Copyright (C) Daniel Stenberg, <daniel@haxx.se>, et al. 2# 3# SPDX-License-Identifier: curl 4 5name: osslq-linux 6 7on: 8 push: 9 branches: 10 - master 11 - '*/ci' 12 paths-ignore: 13 - '**/*.md' 14 - '**/CMakeLists.txt' 15 - '.azure-pipelines.yml' 16 - '.circleci/**' 17 - '.cirrus.yml' 18 - 'appveyor.*' 19 - 'CMake/**' 20 - 'packages/**' 21 - 'plan9/**' 22 - 'projects/**' 23 - 'winbuild/**' 24 pull_request: 25 branches: 26 - master 27 paths-ignore: 28 - '**/*.md' 29 - '**/CMakeLists.txt' 30 - '.azure-pipelines.yml' 31 - '.circleci/**' 32 - '.cirrus.yml' 33 - 'appveyor.*' 34 - 'CMake/**' 35 - 'packages/**' 36 - 'plan9/**' 37 - 'projects/**' 38 - 'winbuild/**' 39 40concurrency: 41 # Hardcoded workflow filename as workflow name above is just Linux again 42 group: osslq-${{ github.event.pull_request.number || github.sha }} 43 cancel-in-progress: true 44 45permissions: {} 46 47env: 48 MAKEFLAGS: -j 3 49 openssl3-version: openssl-3.3.0 50 quictls-version: 3.1.4+quic 51 nghttp3-version: v1.2.0 52 ngtcp2-version: v1.4.0 53 nghttp2-version: v1.61.0 54 mod_h2-version: v2.0.27 55 56jobs: 57 autotools: 58 name: ${{ matrix.build.name }} 59 runs-on: 'ubuntu-latest' 60 timeout-minutes: 60 61 strategy: 62 fail-fast: false 63 matrix: 64 build: 65 - name: openssl-quic 66 configure: >- 67 PKG_CONFIG_PATH="$HOME/openssl3/lib64/pkgconfig" LDFLAGS="-Wl,-rpath,$HOME/openssl3/lib64" 68 --enable-warnings --enable-werror --enable-debug --disable-ntlm 69 --with-test-nghttpx="$HOME/nghttpx/bin/nghttpx" 70 --with-openssl=$HOME/openssl3 --with-openssl-quic 71 --with-nghttp3=$HOME/nghttpx 72 73 steps: 74 - run: | 75 sudo rm -f /etc/apt/sources.list.d/microsoft-prod.list 76 sudo apt-get update 77 sudo apt-get install libtool autoconf automake pkg-config stunnel4 \ 78 libpsl-dev libbrotli-dev libzstd-dev zlib1g-dev libev-dev libc-ares-dev \ 79 nettle-dev libp11-kit-dev libtspi-dev libunistring-dev guile-2.2-dev libtasn1-bin \ 80 libtasn1-6-dev libidn2-0-dev gawk gperf libtss2-dev dns-root-data bison gtk-doc-tools \ 81 texinfo texlive texlive-extra-utils autopoint libev-dev \ 82 apache2 apache2-dev libnghttp2-dev 83 name: 'install prereqs and impacket, pytest, crypto, apache2' 84 85 - name: cache openssl3 86 if: contains(matrix.build.install_steps, 'openssl3') 87 uses: actions/cache@v4 88 id: cache-openssl3 89 env: 90 cache-name: cache-openssl3 91 with: 92 path: /home/runner/openssl3 93 key: ${{ runner.os }}-build-${{ env.cache-name }}-${{ env.openssl3-version }} 94 95 - name: 'install openssl3' 96 if: steps.cache-openssl3.outputs.cache-hit != 'true' 97 run: | 98 git clone --quiet --depth=1 -b ${{ env.openssl3-version }} https://github.com/openssl/openssl 99 cd openssl 100 ./config --prefix=$HOME/openssl3 101 make -j1 install_sw 102 cat exporters/openssl.pc 103 104 - name: cache quictls 105 if: contains(matrix.build.install_steps, 'quictls') 106 uses: actions/cache@v4 107 id: cache-quictls 108 env: 109 cache-name: cache-quictls 110 with: 111 path: /home/runner/quictls 112 key: ${{ runner.os }}-build-${{ env.cache-name }}-quictls-${{ env.quictls-version }} 113 114 - name: cache quictls 115 uses: actions/cache@v4 116 id: cache-quictls-no-deprecated 117 env: 118 cache-name: cache-quictls-no-deprecated 119 with: 120 path: /home/runner/quictls 121 key: ${{ runner.os }}-build-${{ env.cache-name }}-${{ env.quictls-version }} 122 123 - if: steps.cache-quictls-no-deprecated.outputs.cache-hit != 'true' 124 run: | 125 cd $HOME 126 git clone --quiet --depth=1 -b openssl-${{ env.quictls-version }} https://github.com/quictls/openssl quictls 127 cd quictls 128 ./config no-deprecated --prefix=$HOME/nghttpx --libdir=$HOME/nghttpx/lib 129 make 130 name: 'build quictls' 131 132 - run: | 133 cd $HOME/quictls 134 make -j1 install_sw 135 name: 'install quictls' 136 137 138 - name: cache nghttp3 139 uses: actions/cache@v4 140 id: cache-nghttp3 141 env: 142 cache-name: cache-nghttp3 143 with: 144 path: /home/runner/nghttp3 145 key: ${{ runner.os }}-build-${{ env.cache-name }}-${{ env.nghttp3-version }} 146 147 - if: steps.cache-nghttp3.outputs.cache-hit != 'true' 148 run: | 149 cd $HOME 150 git clone --quiet --depth=1 -b ${{ env.nghttp3-version }} https://github.com/ngtcp2/nghttp3 151 cd nghttp3 152 git submodule update --init 153 autoreconf -fi 154 ./configure --prefix=$HOME/nghttpx PKG_CONFIG_PATH="$HOME/nghttpx/lib/pkgconfig" --enable-lib-only 155 make 156 name: 'build nghttp3' 157 158 - run: | 159 cd $HOME/nghttp3 160 make install 161 name: 'install nghttp3' 162 163 # depends on all other cached libs built so far 164 - run: | 165 git clone --quiet --depth=1 -b ${{ env.ngtcp2-version }} https://github.com/ngtcp2/ngtcp2 166 cd ngtcp2 167 autoreconf -fi 168 ./configure --prefix=$HOME/nghttpx PKG_CONFIG_PATH="$HOME/nghttpx/lib/pkgconfig" --enable-lib-only --with-openssl 169 make install 170 name: 'install ngtcp2' 171 172 # depends on all other cached libs built so far 173 - run: | 174 git clone --quiet --depth=1 -b ${{ env.nghttp2-version }} https://github.com/nghttp2/nghttp2 175 cd nghttp2 176 autoreconf -fi 177 ./configure --prefix=$HOME/nghttpx PKG_CONFIG_PATH="$HOME/nghttpx/lib/pkgconfig" --enable-http3 178 make install 179 name: 'install nghttp2' 180 181 - name: cache mod_h2 182 uses: actions/cache@v4 183 id: cache-mod_h2 184 env: 185 cache-name: cache-mod_h2 186 with: 187 path: /home/runner/mod_h2 188 key: ${{ runner.os }}-build-${{ env.cache-name }}-${{ env.mod_h2-version }} 189 190 - if: steps.cache-mod_h2.outputs.cache-hit != 'true' 191 run: | 192 cd $HOME 193 git clone --quiet --depth=1 -b ${{ env.mod_h2-version }} https://github.com/icing/mod_h2 194 cd mod_h2 195 autoreconf -fi 196 ./configure 197 make 198 name: 'build mod_h2' 199 200 - run: | 201 cd $HOME/mod_h2 202 sudo make install 203 name: 'install mod_h2' 204 205 - uses: actions/checkout@v4 206 207 - run: | 208 sudo python3 -m pip install -r tests/requirements.txt -r tests/http/requirements.txt 209 name: 'install python test prereqs' 210 211 - run: autoreconf -fi 212 name: 'autoreconf' 213 214 - run: ./configure ${{ matrix.build.configure }} 215 name: 'configure' 216 217 - run: make V=1 218 name: 'make' 219 220 - run: make V=1 examples 221 name: 'make examples' 222 223 - run: make V=1 -C tests 224 name: 'make tests' 225 226 - run: make V=1 test-ci 227 name: 'run tests' 228 229 - run: pytest -v tests 230 name: 'run pytest' 231 env: 232 TFLAGS: "${{ matrix.build.tflags }}" 233 CURL_CI: github 234