Merge PR #166: Update reproducible builds to go1.13

This commit is contained in:
Alessio Treglia
2019-10-21 03:50:43 +02:00
committed by Alexander Bezobchuk
parent 01f32a2061
commit 364c3a7b41
4 changed files with 16 additions and 28 deletions

View File

@@ -8,15 +8,15 @@
set -euo pipefail
GITIAN_CACHE_DIRNAME='.gitian-builder-cache'
GO_DEBIAN_RELEASE='1.12.9-1'
GO_TARBALL="golang-debian-${GO_DEBIAN_RELEASE}.tar.gz"
GO_TARBALL_URL="https://salsa.debian.org/go-team/compiler/golang/-/archive/debian/${GO_DEBIAN_RELEASE}/${GO_TARBALL}"
GO_RELEASE='1.13'
GO_TARBALL="go${GO_RELEASE}.linux-amd64.tar.gz"
GO_TARBALL_URL="https://dl.google.com/go/${GO_TARBALL}"
# Defaults
DEFAULT_SIGN_COMMAND='gpg --detach-sign'
DEFAULT_GAIA_SIGS=${GAIA_SIGS:-'gaia.sigs'}
DEFAULT_GITIAN_REPO='https://github.com/devrandom/gitian-builder'
DEFAULT_GITIAN_REPO='https://github.com/cosmos/gitian-builder'
DEFAULT_GBUILD_FLAGS=''
DEFAULT_SIGS_REPO='https://github.com/cosmos/gaia.sigs'

View File

@@ -23,23 +23,18 @@ remotes:
- "url": "https://github.com/cosmos/gaia.git"
"dir": "gaia"
files:
- "golang-debian-1.12.9-1.tar.gz"
- "go1.13.linux-amd64.tar.gz"
script: |
set -e -o pipefail
GO_SRC_RELEASE=golang-debian-1.12.9-1
GO_SRC_RELEASE=go1.13.linux-amd64
GO_SRC_TARBALL="${GO_SRC_RELEASE}.tar.gz"
# Compile go and configure the environment
export TAR_OPTIONS="--mtime="$REFERENCE_DATE\\\ $REFERENCE_TIME""
export BUILD_DIR=`pwd`
tar xf "${GO_SRC_TARBALL}"
rm -f "${GO_SRC_TARBALL}"
[ -d "${GO_SRC_RELEASE}/" ]
mv "${GO_SRC_RELEASE}/" go/
pushd go/
QUILT_PATCHES=debian/patches quilt push -a
fakeroot debian/rules build RUN_TESTS=false GOCACHE=/tmp/go-cache
popd
[ -d go/ ]
export GOOS=darwin
export GOROOT=${BUILD_DIR}/go
@@ -95,6 +90,7 @@ script: |
pushd ${distsrc}
for prog in gaiacli gaiad; do
GOARCH=${arch} GOROOT_FINAL=${GOROOT} go build -a \
-trimpath \
-gcflags=all=-trimpath=${GOPATH} \
-asmflags=all=-trimpath=${GOPATH} \
-mod=readonly -tags "netgo ledger" \

View File

@@ -23,23 +23,18 @@ remotes:
- "url": "https://github.com/cosmos/gaia.git"
"dir": "gaia"
files:
- "golang-debian-1.12.9-1.tar.gz"
- "go1.13.linux-amd64.tar.gz"
script: |
set -e -o pipefail
GO_SRC_RELEASE=golang-debian-1.12.9-1
GO_SRC_RELEASE=go1.13.linux-amd64
GO_SRC_TARBALL="${GO_SRC_RELEASE}.tar.gz"
# Compile go and configure the environment
export TAR_OPTIONS="--mtime="$REFERENCE_DATE\\\ $REFERENCE_TIME""
export BUILD_DIR=`pwd`
tar xf "${GO_SRC_TARBALL}"
rm -f "${GO_SRC_TARBALL}"
[ -d "${GO_SRC_RELEASE}/" ]
mv "${GO_SRC_RELEASE}/" go/
pushd go/
QUILT_PATCHES=debian/patches quilt push -a
fakeroot debian/rules build RUN_TESTS=false GOCACHE=/tmp/go-cache
popd
[ -d go/ ]
export GOROOT=${BUILD_DIR}/go
export GOPATH=${BUILD_DIR}/gopath
@@ -94,6 +89,7 @@ script: |
pushd ${distsrc}
for prog in gaiacli gaiad; do
GOARCH=${arch} GOROOT_FINAL=${GOROOT} go build -a \
-trimpath \
-gcflags=all=-trimpath=${GOPATH} \
-asmflags=all=-trimpath=${GOPATH} \
-mod=readonly -tags "netgo ledger" \

View File

@@ -23,23 +23,18 @@ remotes:
- "url": "https://github.com/cosmos/gaia.git"
"dir": "gaia"
files:
- "golang-debian-1.12.9-1.tar.gz"
- "go1.13.linux-amd64.tar.gz"
script: |
set -e -o pipefail
GO_SRC_RELEASE=golang-debian-1.12.9-1
GO_SRC_RELEASE=go1.13.linux-amd64
GO_SRC_TARBALL="${GO_SRC_RELEASE}.tar.gz"
# Compile go and configure the environment
export TAR_OPTIONS="--mtime="$REFERENCE_DATE\\\ $REFERENCE_TIME""
export BUILD_DIR=`pwd`
tar xf "${GO_SRC_TARBALL}"
rm -f "${GO_SRC_TARBALL}"
[ -d "${GO_SRC_RELEASE}/" ]
mv "${GO_SRC_RELEASE}/" go/
pushd go/
QUILT_PATCHES=debian/patches quilt push -a
fakeroot debian/rules build RUN_TESTS=false GOCACHE=/tmp/go-cache
popd
[ -d go/ ]
export GOOS=windows
export GOROOT=${BUILD_DIR}/go
@@ -96,6 +91,7 @@ script: |
for prog in gaiacli gaiad; do
exe=${prog}.exe
GOARCH=${arch} GOROOT_FINAL=${GOROOT} go build -a \
-trimpath \
-gcflags=all=-trimpath=${GOPATH} \
-asmflags=all=-trimpath=${GOPATH} \
-mod=readonly -tags "netgo ledger" \