aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/Makefile
diff options
context:
space:
mode:
authorJason A. Donenfeld <Jason@zx2c4.com>2019-04-09 02:20:40 +0200
committerJason A. Donenfeld <Jason@zx2c4.com>2019-04-09 02:20:40 +0200
commit5e9b58da50f491ff61d97e7fde36510f7fa4ea1c (patch)
tree366b52f94be86b86282c43bdd195a892b1581fb7 /Makefile
parentservice: use WireGuardTunnel$ prefix (diff)
downloadwireguard-windows-5e9b58da50f491ff61d97e7fde36510f7fa4ea1c.tar.xz
wireguard-windows-5e9b58da50f491ff61d97e7fde36510f7fa4ea1c.zip
build: go 1.12.2 contains my fix for CVE-2019-9634
Signed-off-by: Jason A. Donenfeld <Jason@zx2c4.com>
Diffstat (limited to '')
-rw-r--r--Makefile13
1 files changed, 2 insertions, 11 deletions
diff --git a/Makefile b/Makefile
index a2f0a898..720c0099 100644
--- a/Makefile
+++ b/Makefile
@@ -4,26 +4,17 @@ WINDRES := x86_64-w64-mingw32-windres
export CGO_ENABLED := 1
export GOOS := windows
export GOARCH := amd64
-REAL_GOROOT := $(shell go env GOROOT)
-export GOROOT := $(PWD)/.deps/go
-export PATH := $(GOROOT)/bin:$(PATH)
DEPLOYMENT_HOST ?= winvm
DEPLOYMENT_PATH ?= Desktop
all: wireguard.exe
-.deps/prepared:
- mkdir -p .deps
- rsync -a --delete --exclude=pkg/obj/go-build "$(REAL_GOROOT)/" "$(GOROOT)/"
- patch -f -N -r- -d .deps/go -p1 < golang-runtime-dll-injection.patch
- touch "$@"
-
resources.syso: resources.rc manifest.xml ui/icon/icon.ico
$(WINDRES) -i $< -o $@ -O coff
rwildcard=$(foreach d,$(wildcard $1*),$(call rwildcard,$d/,$2) $(filter $(subst *,%,$2),$d))
-wireguard.exe: resources.syso $(call rwildcard,,*.go *.c *.h) .deps/prepared
+wireguard.exe: resources.syso $(call rwildcard,,*.go *.c *.h)
go build -ldflags="-H windowsgui -s -w" -v -o $@
deploy: wireguard.exe
@@ -31,6 +22,6 @@ deploy: wireguard.exe
scp wireguard.exe $(DEPLOYMENT_HOST):$(DEPLOYMENT_PATH)
clean:
- rm -rf resources.syso wireguard.exe .deps
+ rm -rf resources.syso wireguard.exe
.PHONY: deploy clean all