diff options
-rw-r--r-- | dev-go/go-text/Manifest | 1 | ||||
-rw-r--r-- | dev-go/go-text/go-text-0_pre20150806.ebuild | 50 |
2 files changed, 51 insertions, 0 deletions
diff --git a/dev-go/go-text/Manifest b/dev-go/go-text/Manifest index 98f67bf03717..691a67cbcd2d 100644 --- a/dev-go/go-text/Manifest +++ b/dev-go/go-text/Manifest @@ -1 +1,2 @@ DIST go-text-0_pre20150604.tar.gz 3719061 SHA256 71017417b42ea4e68ac77303782c83b627bfbceed041a1467ddc6319c78923ad SHA512 1bbc5bff271243ee31e346a79abf9dd128907cea82fa1eaba11be62780bd1f6b6b76a2ae9476fbe350224f450e75d12efcffd67521b49d6bec44ce2bb085f0d3 WHIRLPOOL e953d99d661537c8838757ae507f2adda3319ef22ce687a39533351201c5bb7206701db4b54f7c0e4d6df803b378a4f587a2015646825b4c3dfad97696baed2e +DIST go-text-0_pre20150806.tar.gz 3736536 SHA256 377d3a95ffb01cf301e1b6050b1437f576f6bbfe32b6d97afc343bb0570b141f SHA512 dd0fc8b5abdfa6f005316bb7828c03a081485e0bd33cbf86c0b83f8bf9240973a7b0a2e6f52ef75f48ec00fc922be21a6c65ff9eb4080f28cb3f280bd4c4f5c6 WHIRLPOOL 79b6233c99984b98b5e74915029117e1f920e17789033ce2656d1590fbeafd4c69d145adeff7c57b1c7f8836397466461744959557877d27fc831da97a62b6ff diff --git a/dev-go/go-text/go-text-0_pre20150806.ebuild b/dev-go/go-text/go-text-0_pre20150806.ebuild new file mode 100644 index 000000000000..532853bbbbf5 --- /dev/null +++ b/dev-go/go-text/go-text-0_pre20150806.ebuild @@ -0,0 +1,50 @@ +# Copyright 1999-2015 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Id$ + +EAPI=5 + +EGO_PN=golang.org/x/text/... +EGO_SRC=golang.org/x/text + +if [[ ${PV} = *9999* ]]; then + inherit golang-vcs +else + KEYWORDS="~amd64" + EGIT_COMMIT="1309a1875a4368c12688b9383c6bcac738c17c29" + SRC_URI="https://github.com/golang/text/archive/${EGIT_COMMIT}.tar.gz -> ${P}.tar.gz" + inherit golang-vcs-snapshot +fi +inherit golang-build + +DESCRIPTION="Go text processing support" +HOMEPAGE="https://godoc.org/golang.org/x/text" +LICENSE="BSD" +SLOT="0/${PV}" +IUSE="" +DEPEND="" +RDEPEND="" + +src_compile() { + # Create a writable GOROOT in order to avoid sandbox violations. + cp -sR "$(go env GOROOT)" "${T}/goroot" || die + rm -rf "${T}/goroot/src/${EGO_SRC}" || die + rm -rf "${T}/goroot/pkg/$(go env GOOS)_$(go env GOARCH)/${EGO_SRC}" || die + export GOROOT="${T}/goroot" + golang-build_src_compile +} + +src_test() { + # Create go symlink for TestLinking in display/dict_test.go + mkdir -p "${GOROOT}/bin" + ln -s /usr/bin/go "${GOROOT}/bin/go" || die + golang-build_src_test +} + +src_install() { + golang-build_src_install + export -n GOROOT + exeopts -m0755 -p # preserve timestamps for bug 551486 + exeinto "$(go env GOROOT)/bin" + doexe bin/* +} |