From f74f95171f0299707d91d27d89a82b6d51d06346 Mon Sep 17 00:00:00 2001 From: Thomas Voss Date: Tue, 28 May 2024 10:09:18 +0200 Subject: Add a dist target for cross-compilation --- Makefile | 11 +++++++++++ 1 file changed, 11 insertions(+) (limited to 'Makefile') diff --git a/Makefile b/Makefile index 8e71ffb..ba7f802 100644 --- a/Makefile +++ b/Makefile @@ -22,5 +22,16 @@ install: cp ${target}.1 ${DPREFIX}/share/man/man1 cp ${target}.5 ${DPREFIX}/share/man/man5 +dist: + mkdir -p dist + for os in darwin linux windows; do \ + for arch in amd64 arm64; do \ + GOARCH=$$arch GOOS=$$os go build -o dist/gsp-$$os-$$arch; \ + done; \ + done + test: go test ./... + +clean: + rm -rf dist -- cgit v1.2.3