commit 5ae0dd9faf3457d7302069345a366a92b8b3fde0 Author: David Fifield david@bamsoftware.com Date: Thu Jul 17 17:01:19 2014 +0000
Upgrade go to 1.3.
The cross-cgo.patch file is deleted, because cgo in cross builds is fixed in 1.3. http://golang.org/doc/go1.3#gocmd https://code.google.com/p/go/issues/detail?id=4714#c28
The download page moved to http://golang.org/dl/. golang.org has https, but the Wget 1.13.4 from Ubuntu 12.04 doesn't have SNI support, which appears to be necessary: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=653267
--2014-07-17 17:20:11-- https://golang.org/dl/go1.3.src.tar.gz Resolving golang.org (golang.org)... 74.125.20.141, 2607:f8b0:400e:c01::8d Connecting to golang.org (golang.org)|74.125.20.141|:443... connected. ERROR: no certificate subject alternative name matches requested host name `golang.org'. To connect to golang.org insecurely, use `--no-check-certificate'. --- .../mac/gitian-pluggable-transports.yml | 20 ++++++++++---------- .../windows/gitian-pluggable-transports.yml | 20 +++++++++++--------- gitian/fetch-inputs.sh | 4 ++-- gitian/patches/cross-cgo.patch | 16 ---------------- gitian/versions | 6 +++--- gitian/versions.alpha | 6 +++--- gitian/versions.beta | 6 +++--- gitian/versions.nightly | 6 +++--- 8 files changed, 35 insertions(+), 49 deletions(-)
diff --git a/gitian/descriptors/mac/gitian-pluggable-transports.yml b/gitian/descriptors/mac/gitian-pluggable-transports.yml index 420b94d..51fe9d0 100644 --- a/gitian/descriptors/mac/gitian-pluggable-transports.yml +++ b/gitian/descriptors/mac/gitian-pluggable-transports.yml @@ -41,7 +41,6 @@ files: - "m2crypto.tar.gz" - "parsley.tar.gz" - "go.tar.gz" -- "cross-cgo.patch" - "apple-uni-sdk-10.6_20110407-0.flosoft1_i386.deb" - "multiarch-darwin11-cctools127.2-gcc42-5666.3-llvmgcc42-2336.1-Linux-120724.tar.xz" - "dzip.sh" @@ -85,12 +84,13 @@ script: | export GOOS=darwin export GOARCH=386 tar xvf go.tar.gz - cd go - patch -p1 < ~/build/cross-cgo.patch - cd src - # Disable CC et al. that are set up for cross builds. (The Go compiler is a - # cross-compiler, but it needs to run on *this* host.) - CC= CFLAGS= LDFLAGS= LDSHARED= ./make.bash + cd go/src + # http://golang.org/cmd/cgo/: + # "To enable cgo during cross compiling builds, set the CGO_ENABLED + # environment variable to 1 when building the Go tools with make.bash. Also, + # set CC_FOR_TARGET to the C cross compiler for the target. CC will be used + # for compiling for the host." + CGO_ENABLED=1 CC_FOR_TARGET="$CC $CFLAGS $LDFLAGS" CC= CFLAGS= LDFLAGS= ./make.bash cd ../.. export PATH="$PATH:$PWD/go/bin"
@@ -227,7 +227,7 @@ script: | find -type f | xargs touch --date="$REFERENCE_DATETIME" mkdir -p "$GOPATH/src/git.torproject.org/pluggable-transports" ln -sf "$PWD" "$GOPATH/src/git.torproject.org/pluggable-transports/goptlib.git" - CGO_ENABLED=1 CC="$CC $CFLAGS $LDFLAGS" go install git.torproject.org/pluggable-transports/goptlib.git + go install git.torproject.org/pluggable-transports/goptlib.git cd ..
# Building meek @@ -236,11 +236,11 @@ script: | cd meek-client # https://code.google.com/p/go/issues/detail?id=4714#c7 # We need cgo for crypto/x509 support on mac. - CGO_ENABLED=1 CC="$CC $CFLAGS $LDFLAGS" go build + go build cp -a meek-client $PTDIR cd .. cd meek-client-torbrowser - CGO_ENABLED=1 CC="$CC $CFLAGS $LDFLAGS" go build + go build cp -a meek-client-torbrowser $PTDIR cd .. mkdir -p $TBDIR/Docs/meek diff --git a/gitian/descriptors/windows/gitian-pluggable-transports.yml b/gitian/descriptors/windows/gitian-pluggable-transports.yml index d68ace4..fc06cd9 100644 --- a/gitian/descriptors/windows/gitian-pluggable-transports.yml +++ b/gitian/descriptors/windows/gitian-pluggable-transports.yml @@ -48,7 +48,6 @@ files: - "python.msi" - "py2exe.exe" - "go.tar.gz" -- "cross-cgo.patch" - "dzip.sh" - "pyc-timestamp.sh" - "openssl-win32-utils.zip" @@ -139,10 +138,13 @@ script: | export GOOS=windows export GOARCH=386 tar xvf go.tar.gz - cd go - patch -p1 < ~/build/cross-cgo.patch - cd src - ./make.bash + cd go/src + # http://golang.org/cmd/cgo/: + # "To enable cgo during cross compiling builds, set the CGO_ENABLED + # environment variable to 1 when building the Go tools with make.bash. Also, + # set CC_FOR_TARGET to the C cross compiler for the target. CC will be used + # for compiling for the host." + CGO_ENABLED=1 CC_FOR_TARGET="i686-w64-mingw32-gcc" CC= CFLAGS= LDFLAGS= ./make.bash cd ../.. export PATH="$PATH:$PWD/go/bin"
@@ -295,22 +297,22 @@ script: | find -type f | xargs touch --date="$REFERENCE_DATETIME" mkdir -p "$GOPATH/src/git.torproject.org/pluggable-transports" ln -sf "$PWD" "$GOPATH/src/git.torproject.org/pluggable-transports/goptlib.git" - CGO_ENABLED=1 CC="i686-w64-mingw32-gcc" go install git.torproject.org/pluggable-transports/goptlib.git + go install git.torproject.org/pluggable-transports/goptlib.git cd ..
# Building meek cd meek find -type f | xargs touch --date="$REFERENCE_DATETIME" cd meek-client - CGO_ENABLED=1 CC="i686-w64-mingw32-gcc" go build + go build cp -a meek-client.exe $PTDIR cd .. cd meek-client-torbrowser - CGO_ENABLED=1 CC="i686-w64-mingw32-gcc" go build + go build cp -a meek-client-torbrowser.exe $PTDIR cd .. cd terminateprocess-buffer - CGO_ENABLED=1 CC="i686-w64-mingw32-gcc" go build + go build cp -a terminateprocess-buffer.exe $PTDIR cd .. mkdir -p $INSTDIR/Docs/meek diff --git a/gitian/fetch-inputs.sh b/gitian/fetch-inputs.sh index d318fa5..086085c 100755 --- a/gitian/fetch-inputs.sh +++ b/gitian/fetch-inputs.sh @@ -158,7 +158,7 @@ done
# XXX: Omit googlecode.com packages because Google won't allow wget -N # and because the download seems to 404 about 50% of the time. -for i in ARGPARSE GO +for i in ARGPARSE do PACKAGE="${i}_PACKAGE" URL="${MIRROR_URL_DCF}${!PACKAGE}" @@ -172,7 +172,7 @@ do get "${!PACKAGE}" "${MIRROR_URL_ASN}${!PACKAGE}" done
-for i in ZOPEINTERFACE TWISTED PY2EXE SETUPTOOLS PARSLEY +for i in ZOPEINTERFACE TWISTED PY2EXE SETUPTOOLS PARSLEY GO do URL="${i}_URL" PACKAGE="${i}_PACKAGE" diff --git a/gitian/patches/cross-cgo.patch b/gitian/patches/cross-cgo.patch deleted file mode 100644 index eebe0d0..0000000 --- a/gitian/patches/cross-cgo.patch +++ /dev/null @@ -1,16 +0,0 @@ ---- a/src/cmd/go/build.go 2014-02-17 05:38:55.806060278 +0000 -+++ b/src/cmd/go/build.go 2014-02-17 05:39:40.414057143 +0000 -@@ -1928,9 +1928,10 @@ - ) - - func (b *builder) cgo(p *Package, cgoExe, obj string, gccfiles []string, gxxfiles []string) (outGo, outObj []string, err error) { -- if goos != toolGOOS { -- return nil, nil, errors.New("cannot use cgo when compiling for a different operating system") -- } -+ // https://code.google.com/p/go/issues/detail?id=4714#c7 -+ // if goos != toolGOOS { -+ // return nil, nil, errors.New("cannot use cgo when compiling for a different operating system") -+ // } - - cgoCPPFLAGS := stringList(envList("CGO_CPPFLAGS"), p.CgoCPPFLAGS) - cgoCFLAGS := stringList(envList("CGO_CFLAGS"), p.CgoCFLAGS) diff --git a/gitian/versions b/gitian/versions index e1b4f55..0372cf7 100755 --- a/gitian/versions +++ b/gitian/versions @@ -44,7 +44,7 @@ SETUPTOOLS_VER=1.4 LXML_VER=3.3.5 PARSLEY_VER=1.2 HTTPSE_VER=3.5.1 -GO_VER=1.2 +GO_VER=1.3
## File names for the source packages OPENSSL_PACKAGE=openssl-${OPENSSL_VER}.tar.gz @@ -89,7 +89,7 @@ M2CRYPTO_HASH=25b94498505c2d800ee465db0cc1aff097b1615adc3ac042a1c85ceca264fc0a PY2EXE_HASH=610a8800de3d973ed5ed4ac505ab42ad058add18a68609ac09e6cf3598ef056c SETUPTOOLS_HASH=75d288687066ed124311d6ca5f40ffa92a0e81adcd7fff318c6e84082713cf39 PARSLEY_HASH=50d30cee70770fd44db7cea421cb2fb75af247c3a1cd54885c06b30a7c85dd23 -GO_HASH=9ab83fb8eafe39f4204ef0f8e84e5ff7e8f1d533ddb05f51e6dc81503e8c0ae4 +GO_HASH=eb983e6c5b2b9838f482c5442b1ac1856f610f2b21f3c123b3fedb48ffc35382
## Non-git package URLs OPENSSL_URL=https://www.openssl.org/source/$%7BOPENSSL_PACKAGE%7D @@ -114,4 +114,4 @@ PY2EXE_URL=http://softlayer-dal.dl.sourceforge.net/project/py2exe/py2exe/$%7BPY2EX SETUPTOOLS_URL=https://pypi.python.org/packages/source/s/setuptools/$%7BSETUPTOOLS_PACKAGE%... LXML_URL=https://pypi.python.org/packages/source/l/lxml/$%7BLXML_PACKAGE%7D PARSLEY_URL=https://pypi.python.org/packages/source/P/Parsley/$%7BPARSLEY_PACKAGE%7D -GO_URL=https://go.googlecode.com/files/$%7BGO_PACKAGE%7D +GO_URL=http://golang.org/dl/$%7BGO_PACKAGE%7D diff --git a/gitian/versions.alpha b/gitian/versions.alpha index b406f45..6be86bd 100755 --- a/gitian/versions.alpha +++ b/gitian/versions.alpha @@ -44,7 +44,7 @@ SETUPTOOLS_VER=1.4 LXML_VER=3.3.5 PARSLEY_VER=1.2 HTTPSE_VER=3.5.3 -GO_VER=1.2 +GO_VER=1.3
## File names for the source packages OPENSSL_PACKAGE=openssl-${OPENSSL_VER}.tar.gz @@ -89,7 +89,7 @@ M2CRYPTO_HASH=25b94498505c2d800ee465db0cc1aff097b1615adc3ac042a1c85ceca264fc0a PY2EXE_HASH=610a8800de3d973ed5ed4ac505ab42ad058add18a68609ac09e6cf3598ef056c SETUPTOOLS_HASH=75d288687066ed124311d6ca5f40ffa92a0e81adcd7fff318c6e84082713cf39 PARSLEY_HASH=50d30cee70770fd44db7cea421cb2fb75af247c3a1cd54885c06b30a7c85dd23 -GO_HASH=9ab83fb8eafe39f4204ef0f8e84e5ff7e8f1d533ddb05f51e6dc81503e8c0ae4 +GO_HASH=eb983e6c5b2b9838f482c5442b1ac1856f610f2b21f3c123b3fedb48ffc35382
## Non-git package URLs OPENSSL_URL=https://www.openssl.org/source/$%7BOPENSSL_PACKAGE%7D @@ -114,4 +114,4 @@ PY2EXE_URL=http://softlayer-dal.dl.sourceforge.net/project/py2exe/py2exe/$%7BPY2EX SETUPTOOLS_URL=https://pypi.python.org/packages/source/s/setuptools/$%7BSETUPTOOLS_PACKAGE%... LXML_URL=https://pypi.python.org/packages/source/l/lxml/$%7BLXML_PACKAGE%7D PARSLEY_URL=https://pypi.python.org/packages/source/P/Parsley/$%7BPARSLEY_PACKAGE%7D -GO_URL=https://go.googlecode.com/files/$%7BGO_PACKAGE%7D +GO_URL=http://golang.org/dl/$%7BGO_PACKAGE%7D diff --git a/gitian/versions.beta b/gitian/versions.beta index 2594f60..aedcf44 100755 --- a/gitian/versions.beta +++ b/gitian/versions.beta @@ -44,7 +44,7 @@ SETUPTOOLS_VER=1.4 LXML_VER=3.3.5 PARSLEY_VER=1.2 HTTPSE_VER=3.5.1 -GO_VER=1.2 +GO_VER=1.3
## File names for the source packages OPENSSL_PACKAGE=openssl-${OPENSSL_VER}.tar.gz @@ -91,7 +91,7 @@ M2CRYPTO_HASH=25b94498505c2d800ee465db0cc1aff097b1615adc3ac042a1c85ceca264fc0a PY2EXE_HASH=610a8800de3d973ed5ed4ac505ab42ad058add18a68609ac09e6cf3598ef056c SETUPTOOLS_HASH=75d288687066ed124311d6ca5f40ffa92a0e81adcd7fff318c6e84082713cf39 PARSLEY_HASH=50d30cee70770fd44db7cea421cb2fb75af247c3a1cd54885c06b30a7c85dd23 -GO_HASH=9ab83fb8eafe39f4204ef0f8e84e5ff7e8f1d533ddb05f51e6dc81503e8c0ae4 +GO_HASH=eb983e6c5b2b9838f482c5442b1ac1856f610f2b21f3c123b3fedb48ffc35382
## Non-git package URLs OPENSSL_URL=https://www.openssl.org/source/$%7BOPENSSL_PACKAGE%7D @@ -116,4 +116,4 @@ PY2EXE_URL=http://softlayer-dal.dl.sourceforge.net/project/py2exe/py2exe/$%7BPY2EX SETUPTOOLS_URL=https://pypi.python.org/packages/source/s/setuptools/$%7BSETUPTOOLS_PACKAGE%... LXML_URL=https://pypi.python.org/packages/source/l/lxml/$%7BLXML_PACKAGE%7D PARSLEY_URL=https://pypi.python.org/packages/source/P/Parsley/$%7BPARSLEY_PACKAGE%7D -GO_URL=https://go.googlecode.com/files/$%7BGO_PACKAGE%7D +GO_URL=http://golang.org/dl/$%7BGO_PACKAGE%7D diff --git a/gitian/versions.nightly b/gitian/versions.nightly index 5398126..59c55dc 100755 --- a/gitian/versions.nightly +++ b/gitian/versions.nightly @@ -44,7 +44,7 @@ SETUPTOOLS_VER=1.4 LXML_VER=3.3.5 PARSLEY_VER=1.2 HTTPSE_VER=3.5.3 -GO_VER=1.2 +GO_VER=1.3
## File names for the source packages OPENSSL_PACKAGE=openssl-${OPENSSL_VER}.tar.gz @@ -89,7 +89,7 @@ M2CRYPTO_HASH=25b94498505c2d800ee465db0cc1aff097b1615adc3ac042a1c85ceca264fc0a PY2EXE_HASH=610a8800de3d973ed5ed4ac505ab42ad058add18a68609ac09e6cf3598ef056c SETUPTOOLS_HASH=75d288687066ed124311d6ca5f40ffa92a0e81adcd7fff318c6e84082713cf39 PARSLEY_HASH=50d30cee70770fd44db7cea421cb2fb75af247c3a1cd54885c06b30a7c85dd23 -GO_HASH=9ab83fb8eafe39f4204ef0f8e84e5ff7e8f1d533ddb05f51e6dc81503e8c0ae4 +GO_HASH=eb983e6c5b2b9838f482c5442b1ac1856f610f2b21f3c123b3fedb48ffc35382
## Non-git package URLs OPENSSL_URL=https://www.openssl.org/source/$%7BOPENSSL_PACKAGE%7D @@ -114,4 +114,4 @@ PY2EXE_URL=http://softlayer-dal.dl.sourceforge.net/project/py2exe/py2exe/$%7BPY2EX SETUPTOOLS_URL=https://pypi.python.org/packages/source/s/setuptools/$%7BSETUPTOOLS_PACKAGE%... LXML_URL=https://pypi.python.org/packages/source/l/lxml/$%7BLXML_PACKAGE%7D PARSLEY_URL=https://pypi.python.org/packages/source/P/Parsley/$%7BPARSLEY_PACKAGE%7D -GO_URL=https://go.googlecode.com/files/$%7BGO_PACKAGE%7D +GO_URL=http://golang.org/dl/$%7BGO_PACKAGE%7D
tbb-commits@lists.torproject.org