From 5b08439651248acb783cc846c18b4ad921ab5e1b Mon Sep 17 00:00:00 2001 From: William Petit Date: Sun, 21 Jan 2024 15:04:48 +0100 Subject: [PATCH] feat(desktop): build and release linux arm/arm64 versions --- Makefile | 14 +++++++++++--- README.md | 2 +- modd.conf | 2 +- 3 files changed, 13 insertions(+), 5 deletions(-) diff --git a/Makefile b/Makefile index 260c46d..ca19aca 100644 --- a/Makefile +++ b/Makefile @@ -4,6 +4,7 @@ GORELEASER_ARGS ?= release --snapshot --rm-dist GITCHLOG_ARGS ?= SHELL := /bin/bash JDK_PATH ?= /usr/lib/jvm/java-11-openjdk +GOARCH ?= amd64 MKT_GITEA_RELEASE_PROJECT := arcast MKT_GITEA_RELEASE_ORG := arcad @@ -22,9 +23,9 @@ test-go: deps build: build-desktop build-android build-client ## Build artefacts build-desktop: deps ## Build executable - CGO_ENABLED=0 go build \ + CGO_ENABLED=0 GOARCH=$(GOARCH) go build \ -v \ - -o ./bin/desktop \ + -o ./bin/desktop_$(GOARCH) \ ./cmd/desktop build-client: deps ## Build executable @@ -66,7 +67,14 @@ gitea-release: .mktools build rm -rf .gitea-release mkdir -p .gitea-release - cp ./bin/desktop .gitea-release/arcad_player_linux_amd64 + cp ./bin/desktop_amd64 .gitea-release/arcad_player_linux_amd64 + + $(MAKE) GOARCH=arm build-desktop + cp ./bin/desktop_arm .gitea-release/arcad_player_linux_arm + + $(MAKE) GOARCH=arm64 build-desktop + cp ./bin/desktop_arm64 .gitea-release/arcad_player_linux_arm64 + cp ./bin/client .gitea-release/arcad_client_linux_amd64 cp ./android/app/build/outputs/apk/debug/app-debug.apk .gitea-release/arcast_player_debug.apk diff --git a/README.md b/README.md index 2cab055..788a039 100644 --- a/README.md +++ b/README.md @@ -32,4 +32,4 @@ Avoir [Chromium](https://www.chromium.org/chromium-projects/) (ou `Google Chrome #### Dernière version -- Linux: [`amd64`](https://forge.cadoles.com/arcad/arcast/releases/download/latest/arcad_player_linux_amd64) \ No newline at end of file +- Linux: [`amd64`](https://forge.cadoles.com/arcad/arcast/releases/download/latest/arcad_player_linux_amd64), [`arm`]([`amd64`](https://forge.cadoles.com/arcad/arcast/releases/download/latest/arcad_player_linux_arm)), [`arm64`](https://forge.cadoles.com/arcad/arcast/releases/download/latest/arcad_player_linux_arm64) \ No newline at end of file diff --git a/modd.conf b/modd.conf index 5f59064..199c707 100644 --- a/modd.conf +++ b/modd.conf @@ -4,5 +4,5 @@ modd.conf .env { prep: make build-client prep: make build-desktop - daemon: make run RUN_CMD="bin/desktop --debug --log-level debug run" + daemon: make run RUN_CMD="bin/desktop_amd64 --debug --log-level debug run" } \ No newline at end of file