Skip to content

build-and-release

build-and-release #17

Workflow file for this run

name: release
on:
# run it manually
workflow_dispatch:
jobs:
release:
name: release (${{ github.ref_name }})
runs-on: ubuntu-latest
steps:
- name: Use variables
env:
CURL_VERSION: ${{ vars.CURL_VERSION }}
QUICTLS_VERSION: ${{ vars.QUICTLS_VERSION }}
NGTCP2_VERSION: ${{ vars.NGTCP2_VERSION }}
NGHTTP3_VERSION: ${{ vars.NGHTTP3_VERSION }}
NGHTTP2_VERSION: ${{ vars.NGHTTP2_VERSION }}
LIBIDN2_VERSION: ${{ vars.LIBIDN2_VERSION }}
LIBUNISTRING_VERSION: ${{ vars.LIBUNISTRING_VERSION }}
ZLIB_VERSION: ${{ vars.ZLIB_VERSION }}
BROTLI_VERSION: ${{ vars.BROTLI_VERSION }}
ZSTD_VERSION: ${{ vars.ZSTD_VERSION }}
LIBSSH2_VERSION: ${{ vars.LIBSSH2_VERSION }}
run: |
echo "cURL version: ${CURL_VERSION}"
echo "QuicTLS version: ${QUICTLS_VERSION}"
echo "ngtcp2 version: ${NGTCP2_VERSION}"
echo "nghttp3 version: ${NGHTTP3_VERSION}"
echo "nghttp2 version: ${NGHTTP2_VERSION}"
echo "libidn2 version: ${LIBIDN2_VERSION}"
echo "libunistring version: ${LIBUNISTRING_VERSION}"
echo "zlib version: ${ZLIB_VERSION}"
echo "brotli version: ${BROTLI_VERSION}"
echo "zstd version: ${ZSTD_VERSION}"
echo "libssh2 version: ${LIBSSH2_VERSION}"
echo "Home: ${HOME}"
- name: Checkout
uses: actions/checkout@v3
with:
fetch-depth: 1
- name: Cross Build Static cURL
env:
CURL_VERSION: ${{ vars.CURL_VERSION }}
QUICTLS_VERSION: ${{ vars.QUICTLS_VERSION }}
NGTCP2_VERSION: ${{ vars.NGTCP2_VERSION }}
NGHTTP3_VERSION: ${{ vars.NGHTTP3_VERSION }}
NGHTTP2_VERSION: ${{ vars.NGHTTP2_VERSION }}
LIBIDN2_VERSION: ${{ vars.LIBIDN2_VERSION }}
LIBUNISTRING_VERSION: ${{ vars.LIBUNISTRING_VERSION }}
ZLIB_VERSION: ${{ vars.ZLIB_VERSION }}
BROTLI_VERSION: ${{ vars.BROTLI_VERSION }}
ZSTD_VERSION: ${{ vars.ZSTD_VERSION }}
LIBSSH2_VERSION: ${{ vars.LIBSSH2_VERSION }}
TOKEN_READ: ${{ secrets.GITHUB_TOKEN }}
ARCH: "all"
ARCHS: "x86_64 aarch64 armv7l i686 riscv64 s390x mips64 mips64el mips mipsel powerpc64le powerpc"
run: |
ARCH="${ARCH}"
ARCHS="${ARCHS}"
CURL_VERSION=${CURL_VERSION}
QUICTLS_VERSION=${QUICTLS_VERSION}
NGTCP2_VERSION=${NGTCP2_VERSION}
NGHTTP3_VERSION=${NGHTTP3_VERSION}
NGHTTP2_VERSION=${NGHTTP2_VERSION}
LIBIDN2_VERSION=${LIBIDN2_VERSION}
LIBUNISTRING_VERSION=${LIBUNISTRING_VERSION}
ZLIB_VERSION=${ZLIB_VERSION}
BROTLI_VERSION=${BROTLI_VERSION}
ZSTD_VERSION=${ZSTD_VERSION}
LIBSSH2_VERSION=${LIBSSH2_VERSION}
TOKEN_READ=${TOKEN_READ}
sh curl-static-cross.sh
- name: Set up environment
run: |
VERSION=`cat version.txt`
echo "VERSION=$VERSION" >> $GITHUB_ENV
- name: List compiled files
run: |
ls -l release bin
echo
file bin/curl*
echo
sha256sum bin/curl*
- name: Upload Release Asset
uses: softprops/action-gh-release@v1
if: github.ref == 'refs/heads/main'
with:
files: release/curl-static-*.tar.xz
body_path: release/release.md
tag_name: ${{ env.VERSION }}
token: ${{ secrets.GITHUB_TOKEN }}