added build for normal gcc

updated musl output path
This commit is contained in:
Philipp Häfelfinger 2019-06-06 07:22:11 +02:00
parent e302510bcd
commit 6e0a2c17e4
3 changed files with 7 additions and 5 deletions

View File

@ -13,18 +13,18 @@ steps:
- apt-get update && apt-get install musl -y --no-install-recommends musl musl-dev musl-tools
- go get ./...
- go vet ./...
- go build -o dist/PiwigoDirectoryUploader cmd/PiwigoDirectoryUploader/PiwigoDirectoryUploader.go
- go test -cover ./...
- build/build-gcc.sh
- build/build-musl.sh
- go test -cover ./...
when:
branch: master
- name: buildrelease
image: golang
commands:
- apt-get update && apt-get install musl -y --no-install-recommends musl
- apt-get update && apt-get install musl -y --no-install-recommends musl musl-dev musl-tools
- go get ./...
- go test -cover ./...
- build/build-gcc.sh
- build/build-musl.sh
when:
event: tag

2
build/build-gcc.sh Executable file
View File

@ -0,0 +1,2 @@
#!/bin/bash
go build -o dist/PiwigoDirectoryUploader cmd/PiwigoDirectoryUploader/PiwigoDirectoryUploader.go

View File

@ -1,2 +1,2 @@
#!/bin/bash
CC=musl-gcc go build --ldflags '-linkmode external -extldflags "-static"' ./cmd/PiwigoDirectoryUploader/PiwigoDirectoryUploader.go
CC=musl-gcc go build -o dist/PiwigoDirectoryUploaderMusl --ldflags '-linkmode external -extldflags "-static"' ./cmd/PiwigoDirectoryUploader/PiwigoDirectoryUploader.go