Skip to content

Commit

Permalink
Simplify dotnet-core.yml
Browse files Browse the repository at this point in the history
  • Loading branch information
jedisct1 committed Apr 27, 2024
1 parent 43c9557 commit 0849896
Showing 1 changed file with 14 additions and 76 deletions.
90 changes: 14 additions & 76 deletions .github/workflows/dotnet-core.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ on:
- next

jobs:
build-windows:
build-windows-msvc:
runs-on: windows-latest
steps:
- uses: actions/checkout@v3
Expand All @@ -24,32 +24,24 @@ jobs:
name: build-win-x86
path: bin/Win32/Release/v143/dynamic/libsodium.dll

build-windows-arm64:
build-others:
runs-on: ubuntu-latest
steps:
- name: Install Zig
uses: goto-bus-stop/setup-zig@2a9625d550eefc3a9b1a43d342ad655f563f8241
with:
version: 0.12.0
- uses: actions/checkout@v3
- name: build

- name: build-windows-arm64
run: |
zig build -Doptimize=ReleaseFast -Dtarget=aarch64-windows
mv zig-out/bin/sodium_shared.dll zig-out/bin/libsodium.dll
- uses: actions/upload-artifact@v3
with:
name: build-windows-arm64
path: zig-out/bin/libsodium.dll

build-linux-glibc-x64:
runs-on: ubuntu-latest
steps:
- name: Install Zig
uses: goto-bus-stop/setup-zig@2a9625d550eefc3a9b1a43d342ad655f563f8241
with:
version: 0.12.0
- uses: actions/checkout@v3
- name: build
- name: build-linux-x64
run: |
zig build -Doptimize=ReleaseFast -Dtarget=x86_64-linux-gnu.2.17
- name: tests
Expand All @@ -59,14 +51,7 @@ jobs:
name: build-linux-x64
path: zig-out/lib/libsodium.so

build-linux-glibc-arm:
runs-on: ubuntu-latest
steps:
- name: Install Zig
uses: goto-bus-stop/setup-zig@2a9625d550eefc3a9b1a43d342ad655f563f8241
with:
version: 0.12.0
- name: Set up emulation environment
- name: Set up arm emulation environment
run: |
export DEBIAN_FRONTEND=noninteractive
sudo apt-get update
Expand All @@ -75,8 +60,7 @@ jobs:
sudo update-binfmts --enable qemu-arm
sudo update-binfmts --display
sudo ln -s /usr/arm-linux-gnueabihf/lib/ld-linux-armhf.so.* /lib
- uses: actions/checkout@v3
- name: build
- name: build-linux-arm
run: |
zig build -Doptimize=ReleaseFast -Dtarget=arm-linux-gnueabihf.2.23
- name: tests
Expand All @@ -87,14 +71,7 @@ jobs:
name: build-linux-arm
path: zig-out/lib/libsodium.so

build-linux-glibc-arm64:
runs-on: ubuntu-latest
steps:
- name: Install Zig
uses: goto-bus-stop/setup-zig@2a9625d550eefc3a9b1a43d342ad655f563f8241
with:
version: 0.12.0
- name: Set up emulation environment
- name: Set up aarch64 emulation environment
run: |
export DEBIAN_FRONTEND=noninteractive
sudo apt-get update
Expand All @@ -103,8 +80,7 @@ jobs:
sudo update-binfmts --enable qemu-aarch64
sudo update-binfmts --display
sudo ln -s /usr/aarch64-linux-gnu/lib/ld-linux-aarch64.so.* /lib
- uses: actions/checkout@v3
- name: build
- name: build-linux-arm64
run: |
zig build -Doptimize=ReleaseFast -Dtarget=aarch64-linux-gnu.2.23
- name: tests
Expand All @@ -115,56 +91,23 @@ jobs:
name: build-linux-arm64
path: zig-out/lib/libsodium.so

build-linux-musl-x64:
runs-on: ubuntu-latest
container:
image: alpine:3.13
steps:
- name: Set up build environment
run: |
apk update
apk add alpine-sdk ca-certificates xz
- name: Install Zig
uses: goto-bus-stop/setup-zig@2a9625d550eefc3a9b1a43d342ad655f563f8241
with:
version: 0.12.0
- uses: actions/checkout@v3
- name: build
- name: build-linux-musl-x64
run: |
zig build -Doptimize=ReleaseFast -Dtarget=x86_64-linux-musl
- name: tests
run: |
cd zig-out/bin && ./run.sh
- uses: actions/upload-artifact@v3
with:
name: build-linux-musl-x64
path: zig-out/lib/libsodium.a

build-linux-musl-arm:
runs-on: ubuntu-latest
steps:
- name: Install Zig
uses: goto-bus-stop/setup-zig@2a9625d550eefc3a9b1a43d342ad655f563f8241
with:
version: 0.12.0
- uses: actions/checkout@v3
- name: build
- name: build-linux-musl-arm
run: |
zig build -Doptimize=ReleaseFast -Dtarget=arm-linux-musleabihf
- uses: actions/upload-artifact@v3
with:
name: build-linux-musl-arm
path: zig-out/lib/libsodium.a

build-linux-musl-arm64:
runs-on: ubuntu-latest
steps:
- name: Install Zig
uses: goto-bus-stop/setup-zig@2a9625d550eefc3a9b1a43d342ad655f563f8241
with:
version: 0.12.0
- uses: actions/checkout@v3
- name: build
- name: build-linux-musl-arm64
run: |
zig build -Doptimize=ReleaseFast -Dtarget=aarch64-linux-musl
- uses: actions/upload-artifact@v3
Expand Down Expand Up @@ -207,13 +150,8 @@ jobs:
pack:
runs-on: ubuntu-latest
needs:
- build-windows
- build-linux-glibc-x64
- build-linux-glibc-arm
- build-linux-glibc-arm64
- build-linux-musl-x64
- build-linux-musl-arm
- build-linux-musl-arm64
- build-windows-msvc
- build-others
- build-macos-x64
- build-macos-arm64
container:
Expand Down

0 comments on commit 0849896

Please sign in to comment.