0
0
mirror of https://github.com/termux/termux-packages.git synced 2024-12-04 18:45:52 +00:00
Biswapriyo Nath 4e4d9e85d8 fix(main/litespeedtest): Enable CGO for non AArch64 architectures
Fixes the following error
android/amd64 requires external (cgo) linking, but cgo is not enabled
2024-07-29 11:53:30 +05:30

34 lines
912 B
Diff

--- a/Makefile
+++ b/Makefile
@@ -1,8 +1,7 @@
NAME=lite
BINDIR=bin
-VERSION=$(shell git describe --tags || echo "unknown version")
BUILDTIME=$(shell date -u)
-GOBUILD=CGO_ENABLED=0 go build -trimpath -ldflags '-X "github.com/xxf098/LiteSpeedTest/constant.Version=$(VERSION)" \
+GOBUILD=CGO_ENABLED=1 go build -trimpath -ldflags '-X "github.com/xxf098/LiteSpeedTest/constant.Version=$(VERSION)" \
-X "github.com/xxf098/LiteSpeedTest/constant.BuildTime=$(BUILDTIME)" \
-w -s -buildid='
@@ -27,10 +26,8 @@
windows-arm64 \
windows-arm32v7
-all: linux-amd64 darwin-amd64 windows-amd64 # Most used
-
-dockerbin:
- $(GOBUILD) -o $(BINDIR)/$(NAME)-$@
+all:
+ $(GOBUILD) -o $(BINDIR)/$(NAME)
darwin-amd64:
GOARCH=amd64 GOOS=darwin $(GOBUILD) -o $(BINDIR)/$(NAME)-$@
@@ -128,4 +125,5 @@
GOOS=freebsd golangci-lint run ./...
clean:
- rm $(BINDIR)/*
\ No newline at end of file
+ rm $(BINDIR)/*
+