diff options
| author | DanConwayDev <DanConwayDev@protonmail.com> | 2025-06-03 15:34:11 +0100 |
|---|---|---|
| committer | DanConwayDev <DanConwayDev@protonmail.com> | 2025-06-03 15:34:41 +0100 |
| commit | 8b182325ad221e06f20b5778fd4963a4b90622c5 (patch) | |
| tree | feaa1a1af9e407eba0de1ebafaf598ad4b2ee506 /.github | |
| parent | e818946e18c3236f8650f79db3f4d4a2f9bd6d5a (diff) | |
build: fix release binariesv1.7.0
work was done to produce more reslient binaries builds to work across
different distros and version b98d2819288f86dd5b316c726cda0f84a1f63eb5
this commit fixes the job runner so they actual get built
Diffstat (limited to '.github')
| -rw-r--r-- | .github/workflows/release.yml | 36 |
1 files changed, 16 insertions, 20 deletions
diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 2a5303a..c3060b6 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml | |||
| @@ -28,7 +28,7 @@ jobs: | |||
| 28 | # x86_64 | 28 | # x86_64 |
| 29 | # compatibility: Ubuntu 14.04+, Debian 8+, RHEL/CentOS 7+, Fedora 21+, openSUSE, Arch, etc. Any x86-64 distro with glibc ≥ 2.17. (Not Alpine) | 29 | # compatibility: Ubuntu 14.04+, Debian 8+, RHEL/CentOS 7+, Fedora 21+, openSUSE, Arch, etc. Any x86-64 distro with glibc ≥ 2.17. (Not Alpine) |
| 30 | - os: ubuntu-latest | 30 | - os: ubuntu-latest |
| 31 | target: x86_64-unknown-linux-gnu.2.17 # glibc ≥ 2.17 | 31 | target: x86_64-unknown-linux-gnu.2.17 |
| 32 | build-tool: cargo-zigbuild | 32 | build-tool: cargo-zigbuild |
| 33 | # aarch64 | 33 | # aarch64 |
| 34 | # compatibility: Ubuntu 20.04+, Debian 11+, Amazon Linux 2, AWS Graviton, Raspberry Pi OS 64-bit, etc. Any aarch64/arm64 distro with glibc ≥ 2.17. | 34 | # compatibility: Ubuntu 20.04+, Debian 11+, Amazon Linux 2, AWS Graviton, Raspberry Pi OS 64-bit, etc. Any aarch64/arm64 distro with glibc ≥ 2.17. |
| @@ -40,37 +40,33 @@ jobs: | |||
| 40 | - os: ubuntu-latest | 40 | - os: ubuntu-latest |
| 41 | target: x86_64-unknown-linux-musl | 41 | target: x86_64-unknown-linux-musl |
| 42 | build-tool: cargo-zigbuild | 42 | build-tool: cargo-zigbuild |
| 43 | # windows - faster alternative to native windows toolchain | 43 | # # windows - faster alternative to native windows toolchain |
| 44 | # compatibility: Windows 7 SP1 / Server 2008 R2 and newer, including Windows 11. Requires the “Universal C Runtime” which is already present on Windows 10+ or via the VC++ 2015-2022 redistributable on older systems. No other DLLs needed. | 44 | # # compatibility: Windows 7 SP1 / Server 2008 R2 and newer, including Windows 11. Requires the “Universal C Runtime” which is already present on Windows 10+ or via the VC++ 2015-2022 redistributable on older systems. No other DLLs needed. |
| 45 | - os: ubuntu-latest | 45 | # - os: ubuntu-latest |
| 46 | target: x86_64-pc-windows-msvc | 46 | # target: x86_64-pc-windows-msvc |
| 47 | build-tool: cargo-zigbuild | 47 | # build-tool: cargo-zigbuild |
| 48 | # ---------- macOS (needs real mac runner) ------------- | 48 | # ---------- macOS (needs real mac runner) ------------- |
| 49 | # compatibility: macOS 10.13 High Sierra (2017) or newer. Intel + Apple Silicon. | 49 | # compatibility: macOS 10.13 High Sierra (2017) or newer. Intel + Apple Silicon. |
| 50 | - os: macos-14 | 50 | - os: macos-14 |
| 51 | target: universal-apple-darwin # universal = x86_64 + arm64 | 51 | target: universal-apple-darwin |
| 52 | build-tool: cargo # native cargo is fastest | 52 | build-tool: cargo |
| 53 | # ---------- native Windows toolchain ------------------ | 53 | # ---------- native Windows toolchain ------------------ |
| 54 | # switch to this if issues are reported with the zig build | 54 | # switch to this if issues are reported with the zig build |
| 55 | # - os: windows-latest | 55 | - os: windows-latest |
| 56 | # target: x86_64-pc-windows-msvc | 56 | target: x86_64-pc-windows-msvc |
| 57 | # build-tool: cargo | 57 | build-tool: cargo |
| 58 | runs-on: ${{ matrix.os }} | 58 | runs-on: ${{ matrix.os }} |
| 59 | env: | ||
| 60 | # make openssl + libgit2 static so the binaries work on old distros | ||
| 61 | OPENSSL_STATIC: 1 | ||
| 62 | # enable Rust LTO + stripping (you can also move this into Cargo.toml) | ||
| 63 | CARGO_PROFILE_RELEASE_LTO: true | ||
| 64 | CARGO_PROFILE_RELEASE_STRIP: symbols | ||
| 65 | |||
| 66 | steps: | 59 | steps: |
| 67 | - uses: actions/checkout@v3 | 60 | - uses: actions/checkout@v3 |
| 68 | # (optional) cache build artefacts; speeds up repeated releases | 61 | - uses: dtolnay/rust-toolchain@stable |
| 69 | - uses: Swatinem/rust-cache@v2 | 62 | - name: Install cargo-zigbuild using Homebrew for macOS |
| 63 | if: runner.os == 'macOS' && matrix.build-tool == 'cargo-zigbuild' | ||
| 64 | run: brew install cargo-zigbuild | ||
| 70 | - uses: taiki-e/upload-rust-binary-action@v1 | 65 | - uses: taiki-e/upload-rust-binary-action@v1 |
| 71 | with: | 66 | with: |
| 72 | bin: ngit,git-remote-nostr | 67 | bin: ngit,git-remote-nostr |
| 73 | target: ${{ matrix.target }} | 68 | target: ${{ matrix.target }} |
| 69 | features: vendored-openssl | ||
| 74 | build-tool: ${{ matrix.build-tool }} | 70 | build-tool: ${{ matrix.build-tool }} |
| 75 | # final file name: ngit-v1.6.3-x86_64-unknown-linux-gnu.tar.gz … | 71 | # final file name: ngit-v1.6.3-x86_64-unknown-linux-gnu.tar.gz … |
| 76 | archive: ngit-$tag-${{ matrix.target }} | 72 | archive: ngit-$tag-${{ matrix.target }} |