From 7672c7087a12c00f674ea3707306c59b8e27e35b Mon Sep 17 00:00:00 2001 From: bitshop Date: Fri, 18 Mar 2022 13:23:10 -0400 Subject: [PATCH] Add to build all windows-arm64 / bin-windows-arm64 build option (#638) * Add to build all windows-arm64 / bin-winarm64 builds * update release to build for windows-arm64 * cleanup Co-authored-by: Wade Simmons --- .github/workflows/release.yml | 32 +++++++++++++++++++++++++++----- Makefile | 6 +++++- 2 files changed, 32 insertions(+), 6 deletions(-) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 944cd98..43e2cbd 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -31,7 +31,7 @@ jobs: path: release build-windows: - name: Build Windows amd64 + name: Build Windows runs-on: windows-latest steps: - name: Set up Go 1.17 @@ -45,8 +45,14 @@ jobs: - name: Build run: | echo $Env:GITHUB_REF.Substring(11) - go build -trimpath -ldflags "-X main.Build=$($Env:GITHUB_REF.Substring(11))" -o build\nebula.exe ./cmd/nebula-service - go build -trimpath -ldflags "-X main.Build=$($Env:GITHUB_REF.Substring(11))" -o build\nebula-cert.exe ./cmd/nebula-cert + mkdir build\windows-amd64 + $Env:GOARCH = "amd64" + go build -trimpath -ldflags "-X main.Build=$($Env:GITHUB_REF.Substring(11))" -o build\windows-amd64\nebula.exe ./cmd/nebula-service + go build -trimpath -ldflags "-X main.Build=$($Env:GITHUB_REF.Substring(11))" -o build\windows-amd64\nebula-cert.exe ./cmd/nebula-cert + mkdir build\windows-arm64 + $Env:GOARCH = "arm64" + go build -trimpath -ldflags "-X main.Build=$($Env:GITHUB_REF.Substring(11))" -o build\windows-arm64\nebula.exe ./cmd/nebula-service + go build -trimpath -ldflags "-X main.Build=$($Env:GITHUB_REF.Substring(11))" -o build\windows-arm64\nebula-cert.exe ./cmd/nebula-cert mkdir build\dist\windows mv dist\windows\wintun build\dist\windows\ @@ -117,7 +123,10 @@ jobs: - name: Zip Windows run: | cd windows-latest + cp windows-amd64/* . zip -r nebula-windows-amd64.zip nebula.exe nebula-cert.exe dist + cp windows-arm64/* . + zip -r nebula-windows-arm64.zip nebula.exe nebula-cert.exe dist - name: Create sha256sum run: | @@ -127,9 +136,12 @@ jobs: cd $dir if [ "$dir" = windows-latest ] then - sha256sum