go: include godoc, vet and cover
godoc, vet and cover are part of the official Go distribution, but live in repositories separate from Go itself.
This commit is contained in:
parent
7d234f5175
commit
73cbaa45fe
@ -1,10 +1,10 @@
|
|||||||
# Template file for 'go'
|
# Template file for 'go'
|
||||||
pkgname=go
|
pkgname=go
|
||||||
version=1.3
|
version=1.3
|
||||||
revision=1
|
revision=2
|
||||||
wrksrc=go
|
wrksrc=go
|
||||||
makedepends="ed bison"
|
hostmakedepends="mercurial ca-certificates"
|
||||||
depends="perl gawk"
|
depends="perl"
|
||||||
short_desc="The Go Programming Language"
|
short_desc="The Go Programming Language"
|
||||||
maintainer="Juan RP <xtraeme@gmail.com>"
|
maintainer="Juan RP <xtraeme@gmail.com>"
|
||||||
homepage="http://golang.org/"
|
homepage="http://golang.org/"
|
||||||
@ -23,13 +23,22 @@ do_build() {
|
|||||||
i686*) export GOHOSTARCH=386;;
|
i686*) export GOHOSTARCH=386;;
|
||||||
x86_64*) export GOHOSTARCH=amd64;;
|
x86_64*) export GOHOSTARCH=amd64;;
|
||||||
esac
|
esac
|
||||||
|
case "$XBPS_TARGET_MACHINE" in
|
||||||
|
arm*) targetarch=arm;;
|
||||||
|
i686*) targetarch=386;;
|
||||||
|
x86_64*) targetarch=amd64;;
|
||||||
|
*) targetarch=$GOHOSTARCH;;
|
||||||
|
esac
|
||||||
case "$XBPS_TARGET_MACHINE" in
|
case "$XBPS_TARGET_MACHINE" in
|
||||||
armv6l*) export GOARM=6;;
|
armv6l*) export GOARM=6;;
|
||||||
armv7l*) export GOARM=7;;
|
armv7l*) export GOARM=7;;
|
||||||
esac
|
esac
|
||||||
|
|
||||||
|
export GOROOT=$PWD
|
||||||
export GOROOT_FINAL="/usr/lib/go"
|
export GOROOT_FINAL="/usr/lib/go"
|
||||||
export GOOS=linux
|
export GOOS=linux
|
||||||
|
export GOPATH=/tmp
|
||||||
|
mkdir -p $GOPATH/src
|
||||||
|
|
||||||
cd src
|
cd src
|
||||||
|
|
||||||
@ -41,10 +50,30 @@ do_build() {
|
|||||||
export GOARCH=$arch
|
export GOARCH=$arch
|
||||||
bash make.bash --no-clean
|
bash make.bash --no-clean
|
||||||
done
|
done
|
||||||
|
|
||||||
|
GOARCH=$targetarch
|
||||||
|
|
||||||
|
hg clone -u release-branch.go${version} \
|
||||||
|
--config web.cacerts=/etc/ssl/certs/ca-certificates.crt \
|
||||||
|
https://code.google.com/p/go.tools/ \
|
||||||
|
$GOPATH/src/code.google.com/p/go.tools
|
||||||
|
|
||||||
|
for tool in godoc vet cover; do
|
||||||
|
$GOROOT/bin/go install code.google.com/p/go.tools/cmd/${tool}
|
||||||
|
done
|
||||||
}
|
}
|
||||||
|
|
||||||
do_install() {
|
do_install() {
|
||||||
vinstall LICENSE 644 usr/share/licenses/go
|
vinstall LICENSE 644 usr/share/licenses/go
|
||||||
|
|
||||||
|
# TODO Beginning with Go 1.4, there will be no editor or shell
|
||||||
|
# integration in the Go distribution anymore (see
|
||||||
|
# https://codereview.appspot.com/105470043) - While the emacs
|
||||||
|
# integration has a canonical upstream at
|
||||||
|
# https://github.com/dominikh/go-mode.el, neither vim, bash nor
|
||||||
|
# zsh have one (yet). In any case, there'll need to be made a
|
||||||
|
# decision between pulling 3rd party integration into this
|
||||||
|
# package, providing extra packages, or doing nothing at all.
|
||||||
vinstall misc/bash/go 644 usr/share/bash-completion/completions
|
vinstall misc/bash/go 644 usr/share/bash-completion/completions
|
||||||
vinstall misc/emacs/go-mode-load.el 644 usr/share/emacs/site-lisp
|
vinstall misc/emacs/go-mode-load.el 644 usr/share/emacs/site-lisp
|
||||||
vinstall misc/emacs/go-mode.el 644 usr/share/emacs/site-lisp
|
vinstall misc/emacs/go-mode.el 644 usr/share/emacs/site-lisp
|
||||||
|
Loading…
x
Reference in New Issue
Block a user