summaryrefslogtreecommitdiff
path: root/community/go/PKGBUILD
diff options
context:
space:
mode:
authorroot <root@rshg054.dnsready.net>2012-11-15 01:46:35 -0800
committerroot <root@rshg054.dnsready.net>2012-11-15 01:46:35 -0800
commit2264379d37a6a00a3ecec1fd03c5dd4796078d49 (patch)
treec7d44781aab3d74058a981f8e9035eee06f8f5bc /community/go/PKGBUILD
parent6fa5f08247aef1f757f376ef12bd4a6257c124f2 (diff)
Thu Nov 15 01:46:22 PST 2012
Diffstat (limited to 'community/go/PKGBUILD')
-rw-r--r--community/go/PKGBUILD20
1 files changed, 15 insertions, 5 deletions
diff --git a/community/go/PKGBUILD b/community/go/PKGBUILD
index d57e9373a..5e2afb2e5 100644
--- a/community/go/PKGBUILD
+++ b/community/go/PKGBUILD
@@ -1,4 +1,4 @@
-# $Id: PKGBUILD 77818 2012-10-15 00:41:07Z arodseth $
+# $Id: PKGBUILD 79946 2012-11-15 01:53:41Z arodseth $
# Maintainer: Vesa Kaihlavirta <vegai@iki.fi>
# Maintainer: Alexander Rødseth <rodseth@gmail.com>
# Contributor: Rémy Oudompheng <remy@archlinux.org>
@@ -10,7 +10,7 @@
pkgname=go
pkgver=1.0.3
-pkgrel=2
+pkgrel=3
epoch=2
pkgdesc='Google Go compiler and tools'
arch=('x86_64' 'i686')
@@ -27,6 +27,8 @@ sha256sums=('7fba3533d172f13629d3d8a79e57c620632b0bd075abe11d7698b338be0ae3df'
'a03db71d323ed2794123bb31b5c8ad5febd551c490b5c0b341052c8e5f0ba892')
build() {
+ cd $srcdir/$pkgname
+
if [ "$CARCH" == 'x86_64' ]; then
export GOARCH=amd64
fi
@@ -34,18 +36,26 @@ build() {
export GOARCH=386
fi
- # Set GOARCH to arm for crosscompilation (currently doesn't work)
-
- cd $srcdir/$pkgname
export GOROOT_FINAL=/usr/lib/go
export GOOS=linux
cd src
bash make.bash
+
+ # Enable ARM crosscompilation
+ export GOARCH=arm
+ bash make.bash
}
check() {
cd $srcdir/$pkgname
+ if [ "$CARCH" == 'x86_64' ]; then
+ export GOARCH=amd64
+ fi
+ if [ "$CARCH" == 'i686' ]; then
+ export GOARCH=386
+ fi
+
export GOROOT=$srcdir/$pkgname
export PATH=$srcdir/$pkgname/bin:$PATH