aboutsummaryrefslogtreecommitdiffstats
path: root/Makefile
diff options
context:
space:
mode:
authortechknowlogick <techknowlogick@gitea.io>2020-08-24 17:46:41 -0400
committerGitHub <noreply@github.com>2020-08-24 17:46:41 -0400
commit125ffb87f0d14b75f89acf2a47dc13c0f6577774 (patch)
tree83dbe3a24b977542259ecfeea87d9f7341664293 /Makefile
parent4b97f9018b51c1ef56c16154931123aac6080445 (diff)
downloadgitea-125ffb87f0d14b75f89acf2a47dc13c0f6577774.tar.gz
gitea-125ffb87f0d14b75f89acf2a47dc13c0f6577774.zip
go1.15 on windows (#12589)
* go1.15 on windows * update xgo to use node14
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile5
1 files changed, 3 insertions, 2 deletions
diff --git a/Makefile b/Makefile
index d0c1fdabfa..bfeccf82e0 100644
--- a/Makefile
+++ b/Makefile
@@ -42,8 +42,10 @@ ifeq ($(HAS_GO), GO)
endif
ifeq ($(OS), Windows_NT)
+ GOFLAGS := -v -buildmode=exe
EXECUTABLE ?= gitea.exe
else
+ GOFLAGS := -v
EXECUTABLE ?= gitea
endif
@@ -55,7 +57,6 @@ endif
GOFMT ?= gofmt -s
-GOFLAGS := -v
EXTRA_GOFLAGS ?=
MAKE_VERSION := $(shell $(MAKE) -v | head -n 1)
@@ -556,7 +557,7 @@ release-windows: | $(DIST_DIRS)
GO111MODULE=off $(GO) get -u src.techknowlogick.com/xgo; \
fi
@echo "Warning: windows version is built using golang 1.14"
- CGO_CFLAGS="$(CGO_CFLAGS)" GO111MODULE=off xgo -go go-1.14.x -dest $(DIST)/binaries -tags 'netgo osusergo $(TAGS)' -ldflags '-linkmode external -extldflags "-static" $(LDFLAGS)' -targets 'windows/*' -out gitea-$(VERSION) .
+ CGO_CFLAGS="$(CGO_CFLAGS)" GO111MODULE=off xgo -go $(XGO_VERSION) -buildmode exe -dest $(DIST)/binaries -tags 'netgo osusergo $(TAGS)' -ldflags '-linkmode external -extldflags "-static" $(LDFLAGS)' -targets 'windows/*' -out gitea-$(VERSION) .
ifeq ($(CI),drone)
cp /build/* $(DIST)/binaries
endif