Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use Zig to build aarch64 binaries #1249

Merged
merged 1 commit into from
Jun 6, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
41 changes: 41 additions & 0 deletions .github/workflows/make-plugin-arm.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
name: Make ARM Plugins (Windows/macOS/Linux)

on:
workflow_dispatch:
inputs:
version_number:
description: 'Version number'
required: true
default: '1.x.x'

jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
hronro marked this conversation as resolved.
Show resolved Hide resolved
with:
submodules: 'recursive'
- name: Setup Zig
run: |
mkdir /zig
curl 'https://ziglang.org/download/0.9.1/zig-linux-x86_64-0.9.1.tar.xz' | tar xJ --strip-components=1 --directory=/zig
ln -s /zig/zig /usr/bin/zig
- name: Build plugin
env:
VERSION: ${{ github.event.inputs.version_number }}
run: |
cd javascript/net/grpc/web/generator
zig build -Drelease-fast
- name: gen and verify sha256
run: |
cd javascript/net/grpc/web/generator/zig-out/bin
for exe in $(ls)
do
openssl dgst -sha256 -r -out $exe'.sha256' $exe
sha256sum -c $exe'.sha256'
done
hronro marked this conversation as resolved.
Show resolved Hide resolved
- name: Upload artifacts
uses: actions/upload-artifact@v3
sampajano marked this conversation as resolved.
Show resolved Hide resolved
with:
name: plugin
path: javascript/net/grpc/web/generator/zig-out/bin/
4 changes: 2 additions & 2 deletions .github/workflows/make-plugin-linux.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v3
- name: Build plugin docker image
run: docker-compose build prereqs protoc-plugin
- name: Copy binary from Docker image
Expand All @@ -26,7 +26,7 @@ jobs:
- name: verify sha256
run: sha256sum -c protoc-gen-grpc-web-${{ github.event.inputs.version_number }}-linux-x86_64.sha256
- name: Upload artifacts
uses: actions/upload-artifact@v2
uses: actions/upload-artifact@v3
with:
name: plugin
path: protoc-gen-grpc-web*
4 changes: 2 additions & 2 deletions .github/workflows/make-plugin-mac-os.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ jobs:
build:
runs-on: macos-latest
steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v3
- name: Install build utils
run: brew install coreutils automake
- name: Checkout protobuf code
Expand Down Expand Up @@ -42,7 +42,7 @@ jobs:
- name: verify sha256
run: sha256sum -c protoc-gen-grpc-web-${{ github.event.inputs.version_number }}-darwin-x86_64.sha256
- name: Upload artifacts
uses: actions/upload-artifact@v2
uses: actions/upload-artifact@v3
with:
name: plugin
path: protoc-gen-grpc-web*
4 changes: 2 additions & 2 deletions .github/workflows/make-plugin-windows.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ jobs:
build:
runs-on: windows-latest
steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v3
- name: Print Bazel version
run: |
bazel version
Expand All @@ -31,7 +31,7 @@ jobs:
# TODO: Check sha256 (sha256sum not available for now. )
#- name: verify sha256
- name: Upload artifacts
uses: actions/upload-artifact@v2
uses: actions/upload-artifact@v3
with:
name: plugin
path: protoc-gen-grpc-web*
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -11,3 +11,5 @@ target
.project
.classpath
.settings
zig-out
zig-cache
Loading