rmfakecloud-proxy/Makefile

37 lines
962 B
Makefile
Raw Normal View History

ARMV7_BINARY=dist/rmfakecloud-proxy-arm7
AARCH64_BINARY=dist/rmfakecloud-proxy-aarch64
WIN_BINARY=dist/rmfakecloud-proxy.exe
LINUX_BINARY=dist/rmfakecloud-proxy64
RM12_INSTALLER=dist/installer-rm12.sh
RMPRO_INSTALLER=dist/installer-rmpro.sh
2021-02-09 17:39:44 +01:00
.PHONY: clean
all: $(RMPRO_INSTALLER) $(RM12_INSTALLER) $(WIN_BINARY) $(LINUX_BINARY)
2021-09-26 23:50:53 +02:00
$(LINUX_BINARY): version.go main.go
2021-09-26 23:50:53 +02:00
go build -ldflags="-w -s" -o $@
$(ARMV7_BINARY): version.go main.go
2021-09-26 23:50:53 +02:00
GOARCH=arm GOARM=7 go build -ldflags="-w -s" -o $@
$(AARCH64_BINARY): version.go main.go
GOARCH=arm64 go build -ldflags="-w -s" -o $@
$(WIN_BINARY): version.go main.go
2021-09-26 23:50:53 +02:00
GOOS=windows go build -ldflags="-w -s" -o $@
2021-02-12 00:36:22 +01:00
version.go:
2021-02-09 17:39:44 +01:00
go generate
2021-02-12 00:36:22 +01:00
$(RMPRO_INSTALLER): $(AARCH64_BINARY) scripts/installer.sh
2021-02-12 01:56:32 +01:00
cp scripts/installer.sh $@
gzip -c $(AARCH64_BINARY) >> $@
2021-02-12 01:56:32 +01:00
chmod +x $@
$(RM12_INSTALLER): $(ARMV7_BINARY) scripts/installer.sh
cp scripts/installer.sh $@
gzip -c $(ARMV7_BINARY) >> $@
chmod +x $@
2021-02-09 17:39:44 +01:00
clean:
2021-02-12 00:36:22 +01:00
rm -fr dist