summaryrefslogtreecommitdiff
path: root/community/go/PKGBUILD
diff options
context:
space:
mode:
authorroot <root@rshg054.dnsready.net>2012-05-13 00:05:25 +0000
committerroot <root@rshg054.dnsready.net>2012-05-13 00:05:25 +0000
commite8aea505d7f36277edd02ef965bc3f8e1c81ee5d (patch)
tree1f61a4443a471430d6430cad09742b6154617cad /community/go/PKGBUILD
parente1da03cf5ba92abee0e3afd9dc4cef438ebf96c7 (diff)
Sun May 13 00:05:24 UTC 2012
Diffstat (limited to 'community/go/PKGBUILD')
-rw-r--r--community/go/PKGBUILD48
1 files changed, 20 insertions, 28 deletions
diff --git a/community/go/PKGBUILD b/community/go/PKGBUILD
index 79fba706b..16f3154b8 100644
--- a/community/go/PKGBUILD
+++ b/community/go/PKGBUILD
@@ -1,4 +1,4 @@
-# $Id: PKGBUILD 70517 2012-05-10 12:42:42Z arodseth $
+# $Id: PKGBUILD 70575 2012-05-11 22:56:57Z remy $
# Maintainer: Vesa Kaihlavirta <vegai@iki.fi>
# Maintainer: Alexander Rødseth <rodseth@gmail.com>
# Contributor: Andres Perera <andres87p gmail>
@@ -9,7 +9,7 @@
pkgname=go
pkgver=1.0.1
-pkgrel=2
+pkgrel=3
epoch=2
pkgdesc='Google Go compiler and tools (release version)'
arch=('x86_64' 'i686')
@@ -19,26 +19,23 @@ depends=('perl' 'gawk')
makedepends=('inetutils')
options=('!strip' '!emptydirs')
install=go.install
-source=("http://go.googlecode.com/files/${pkgname}$pkgver.src.tar.gz"
- "$pkgname.run"
- "$pkgname.sh")
-sha1sums=('fc8a6d6725f7f2bf7c94685c5fd0880c9b7f67f6'
- '655754d95688294b0cf2334a1155432884f92859'
- 'a760c32cbad5a013f384a086efb3b8b8fd88794f')
+source=("http://go.googlecode.com/files/${pkgname}$pkgver.src.tar.gz")
+sha1sums=('fc8a6d6725f7f2bf7c94685c5fd0880c9b7f67f6')
build() {
cd "$srcdir/$pkgname"
-
- export GOROOT="$srcdir/$pkgname"
- export GOOS_FINAL="/usr/lib/go"
+ export GOROOT_FINAL="/usr/lib/go"
export GOOS=linux
- export GOBIN="$GOROOT/bin"
- export PATH="$GOBIN:$PATH"
- mkdir -p "$GOROOT/bin"
- cd "$GOROOT/src"
+ cd src && bash make.bash
+}
- . ./all.bash
+check() {
+ # TestSimpleMulticastListener will fail in standard chroot.
+ cd "$srcdir/$pkgname"
+ export GOROOT="$srcdir/$pkgname"
+ export PATH="$srcdir/$pkgname/bin:$PATH"
+ cd src && bash run.bash --no-rebuild || true
}
package() {
@@ -64,14 +61,14 @@ package() {
mkdir -p $pkgdir/{etc/profile.d,usr/{share/go,lib/go,lib/go/src}}
- cp -r bin $pkgdir/usr
cp -r doc misc -t $pkgdir/usr/share/go
ln -s /usr/share/go/doc $pkgdir/usr/lib/go/doc
- cp -r pkg $pkgdir/usr/lib/go
- cp -r $GOROOT/src/pkg $pkgdir/usr/lib/go/src/
- cp -r $GOROOT/src/cmd $pkgdir/usr/lib/go/src/cmd
- cp -r $GOROOT/src/lib9 $pkgdir/usr/lib/go/src/
- cp -r $GOROOT/lib $pkgdir/usr/lib/go/
+ cp -r --preserve=timestamps bin $pkgdir/usr
+ cp -r --preserve=timestamps pkg $pkgdir/usr/lib/go
+ cp -r --preserve=timestamps $GOROOT/src/pkg $pkgdir/usr/lib/go/src/
+ cp -r --preserve=timestamps $GOROOT/src/cmd $pkgdir/usr/lib/go/src/cmd
+ cp -r --preserve=timestamps $GOROOT/src/lib9 $pkgdir/usr/lib/go/src/
+ cp -r --preserve=timestamps $GOROOT/lib $pkgdir/usr/lib/go/
install -Dm644 src/Make.* $pkgdir/usr/lib/go/src
@@ -85,12 +82,7 @@ package() {
install -Dm644 src/pkg/runtime/cgocall.h \
$pkgdir/usr/lib/go/src/pkg/runtime/cgocall.h
- install $srcdir/go.sh $pkgdir/etc/profile.d/
-
- mv "$pkgdir/usr/bin/go" "$pkgdir/usr/bin/go.elf"
- install -Dm755 "$srcdir/go.run" "$pkgdir/usr/bin/go"
-
- rm "$pkgdir/usr/share/go/doc/articles/wiki/get.bin"
+ rm -f "$pkgdir/usr/share/go/doc/articles/wiki/get.bin"
}
# vim:set ts=2 sw=2 et: