fix segmentation fault on linux

This commit is contained in:
Max Howell 2022-10-21 08:46:44 -04:00
parent b732b4472d
commit 09dcb113f3

View file

@ -9,11 +9,18 @@ versions:
build:
script: |
go build
go build -ldflags="$LDFLAGS"
mkdir -p "{{ prefix }}"/bin
mv hugo "{{ prefix }}"/bin
dependencies:
go.dev: ^1.18 # probs higher than is true
env:
LDFLAGS:
- -s -w
linux:
# or segmentation fault
# fix found here https://github.com/docker-library/golang/issues/402#issuecomment-982204575
LDFLAGS:
- -buildmode=pie
test:
hugo version