Releases: h9j6k/lyrebird_arm
built from 0b10edbb61e0ca6fb70c7d57aeaabf315f1fade1
Official lyrebird repo https://gitlab.torproject.org/tpo/anti-censorship/pluggable-transports/lyrebird/-/commit/0b10edbb61e0ca6fb70c7d57aeaabf315f1fade1
git checkout the above repo and build with changes to Makefile
diff --git a/Makefile b/Makefile
index c8519bb..8d3ed9c 100644
--- a/Makefile
+++ b/Makefile
@@ -1,4 +1,6 @@
VERSION = $(shell git describe | sed 's/lyrebird-//')
-
+BUILDTIME = $(shell date +%Y-%m-%d)
build:
- CGO_ENABLED=0 go build -ldflags="-X main.lyrebirdVersion=$(VERSION)" ./cmd/lyrebird
+ CGO_ENABLED=0 go build -ldflags="-s -w -X main.lyrebirdVersion=$(VERSION) -X main.buildTime=$(BUILDTIME)" ./cmd/lyrebird
+# GOOS=linux GOARCH=arm GOARM=7 go build -ldflags="-s -w -X main.lyrebirdVersion=$(VERSION) -X main.buildTime=$(BUILDTIME) -extldflags=-static" ./cmd/lyrebird
+# GOOS=linux GOARCH=arm64 go build -ldflags="-s -w -X main.lyrebirdVersion=$(VERSION) -X main.buildTime=$(BUILDTIME) -extldflags=-static" ./cmd/lyrebird
Then use upx https://github.com/upx/upx to compress the binaries, sizes go down from ~15MB to 3.5MB.
built from 158cd232a6b134fb2552ca7ecd69d34d66f037c4
Official lyrebird repo https://gitlab.torproject.org/tpo/anti-censorship/pluggable-transports/lyrebird/-/commit/158cd232a6b134fb2552ca7ecd69d34d66f037c4
git checkout the above repo and build with changes to Makefile
diff --git a/Makefile b/Makefile
index c8519bb..77d4be9 100644
--- a/Makefile
+++ b/Makefile
@@ -1,4 +1,6 @@
VERSION = $(shell git describe | sed 's/lyrebird-//')
-
+BUILDTIME = $(shell date +%Y-%m-%d)
build:
- CGO_ENABLED=0 go build -ldflags="-X main.lyrebirdVersion=$(VERSION)" ./cmd/lyrebird
+ #CGO_ENABLED=0 go build -ldflags="-s -w -X main.lyrebirdVersion=$(VERSION)" ./cmd/lyrebird
+ #GOOS=linux GOARCH=arm GOARM=7 go build -ldflags="-s -w -X main.lyrebirdVersion=$(VERSION) -X main.buildTime=$(BUILDTIME) -extldflags=-static" ./cmd/lyrebird
+ GOOS=linux GOARCH=arm64 go build -ldflags="-s -w -X main.lyrebirdVersion=$(VERSION) -X main.buildTime=$(BUILDTIME) -extldflags=-static" ./cmd/lyrebird
Then use upx https://github.com/upx/upx to compress the binaries, sizes go down from ~15MB to 3.5MB.
lyrebird.arm.tgz
lyrebird.arm64.tgz
bed0b4286186dce277d1cd63e2709d243ea807c15e7d580a938054c2d3f1124f lyrebird.arm.tgz
636ad8d6dbdf42e02b7c39ffa3c87003cab8e69d046bed68caab738d739ff25b lyrebird.arm64.tgz