From 6b424213747e586e39ebac1293b8f7b8abd1fdfb Mon Sep 17 00:00:00 2001 From: Nick Craig-Wood Date: Fri, 22 Jun 2018 09:52:16 +0100 Subject: [PATCH] build: build macOS beta releases with native compiler on travis #2309 --- .travis.yml | 2 +- Makefile | 9 ++++++++- 2 files changed, 9 insertions(+), 2 deletions(-) diff --git a/.travis.yml b/.travis.yml index 595389472..09186e120 100644 --- a/.travis.yml +++ b/.travis.yml @@ -47,4 +47,4 @@ deploy: on: all_branches: true go: "1.10.1" - condition: $TRAVIS_OS_NAME == linux && $TRAVIS_PULL_REQUEST == false + condition: $TRAVIS_PULL_REQUEST == false diff --git a/Makefile b/Makefile index be882c94b..3dd4e66a0 100644 --- a/Makefile +++ b/Makefile @@ -177,10 +177,17 @@ ifndef BRANCH_PATH endif @echo Beta release ready at $(BETA_URL) +BUILD_FLAGS := -exclude "^(windows|darwin)/" +ifeq ($(TRAVIS_OS_NAME),osx) + BUILD_FLAGS := -include "^darwin/" -cgo +endif + travis_beta: +ifeq ($(TRAVIS_OS_NAME),linux) go run bin/get-github-release.go -extract nfpm goreleaser/nfpm 'nfpm_.*_Linux_x86_64.tar.gz' +endif git log $(LAST_TAG).. > /tmp/git-log.txt - go run bin/cross-compile.go -release beta-latest -git-log /tmp/git-log.txt -exclude "^windows/" -parallel 8 $(BUILDTAGS) $(TAG)β + go run bin/cross-compile.go -release beta-latest -git-log /tmp/git-log.txt $(BUILD_FLAGS) -parallel 8 $(BUILDTAGS) $(TAG)β rclone --config bin/travis.rclone.conf -v copy --exclude '*beta-latest*' build/ $(BETA_UPLOAD) ifndef BRANCH_PATH rclone --config bin/travis.rclone.conf -v copy --include '*beta-latest*' --include version.txt build/ $(BETA_UPLOAD_ROOT)