From b4dc47f17e0e79d073a9ec16f3ceea7b344f65aa Mon Sep 17 00:00:00 2001 From: CareyWong Date: Mon, 28 Sep 2020 21:18:57 +0800 Subject: [PATCH] Add arm64 compile --- .github/workflows/go.yml | 4 ++-- Makefile | 6 ++++++ 2 files changed, 8 insertions(+), 2 deletions(-) diff --git a/.github/workflows/go.yml b/.github/workflows/go.yml index 3fafd25..5817dd5 100644 --- a/.github/workflows/go.yml +++ b/.github/workflows/go.yml @@ -10,10 +10,10 @@ jobs: name: Build runs-on: ubuntu-latest steps: - - name: Set up Go 1.13 + - name: Set up Go 1.14 uses: actions/setup-go@v1 with: - go-version: 1.13 + go-version: 1.14 id: go - name: Check out code into the Go module directory uses: actions/checkout@v2 diff --git a/Makefile b/Makefile index 3013805..27e4f21 100644 --- a/Makefile +++ b/Makefile @@ -2,6 +2,7 @@ BINARY_DEFAULT="build/myurls.service" BINARY_LINUX="build/linux-amd64-myurls.service" BINARY_DARWIN="build/darwin-amd64-myurls.service" BINARY_WINDOWS="build/windows-amd64-myurls.service" +BINARY_ARRCH64="build/arrch64-myurls.service" GOFILES="main.go" VERSION=1.0.0 @@ -31,6 +32,10 @@ windows: @echo ${BINARY_WINDOWS} @CGO_ENABLED=0 GOOS=windows GOARCH=amd64 go build -o ${BINARY_WINDOWS} ${GOFILES} +aarch64: + @echo ${BINARY_ARRCH64} + @CGO_ENABLED=0 GOOS=windows GOARCH=aarch64 go build -o ${BINARY_ARRCH64} ${GOFILES} + install: @go mod tidy @@ -42,3 +47,4 @@ clean: @if [ -f ${BINARY_LINUX} ] ; then rm ${BINARY_LINUX} ; fi @if [ -f ${BINARY_DARWIN} ] ; then rm ${BINARY_DARWIN} ; fi @if [ -f ${BINARY_WINDOWS} ] ; then rm ${BINARY_WINDOWS} ; fi + @if [ -f ${BINARY_ARRCH64} ] ; then rm ${BINARY_ARRCH64} ; fi