From febf0aec8beb40d4e8c0886ca404ab1825542ab2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bj=C3=B8rn=20Erik=20Pedersen?= Date: Mon, 9 Jul 2018 20:42:08 +0200 Subject: [PATCH] Build a fully static Windows extended binary --- goreleaser-extended.yml | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/goreleaser-extended.yml b/goreleaser-extended.yml index 4564ac08b..b953b9e7a 100644 --- a/goreleaser-extended.yml +++ b/goreleaser-extended.yml @@ -1,11 +1,14 @@ project_name: hugo_extended builds: - binary: hugo - ldflags: -s -w -X github.com/gohugoio/hugo/hugolib.BuildDate={{.Date}} + ldflags: + - -s -w -X github.com/gohugoio/hugo/hugolib.BuildDate={{.Date}} + - "-extldflags '-static'" env: - CGO_ENABLED=1 - CC=x86_64-w64-mingw32-gcc - CXX=x86_64-w64-mingw32-g++ + - CGO_LDFLAGS="-static" flags: - -tags - extended