diff options
author | Zac Medico <zmedico@gentoo.org> | 2015-06-03 07:06:05 +0000 |
---|---|---|
committer | Zac Medico <zmedico@gentoo.org> | 2015-06-03 07:06:05 +0000 |
commit | c7468302e6d11ed1910676a7c6d68274445e1a6d (patch) | |
tree | 4a90c7e0bfadfd47f5a0510d7663dc3460eff713 /dev-go | |
parent | Add ruby21, ruby22. (diff) | |
download | historical-c7468302e6d11ed1910676a7c6d68274445e1a6d.tar.gz historical-c7468302e6d11ed1910676a7c6d68274445e1a6d.tar.bz2 historical-c7468302e6d11ed1910676a7c6d68274445e1a6d.zip |
Add favicon to the godoc web interface (bug 551030).
Package-Manager: portage-2.2.20/cvs/Linux x86_64
Manifest-Sign-Key: 0xFDE8EF85AE5719A3
Diffstat (limited to 'dev-go')
-rw-r--r-- | dev-go/go-tools/ChangeLog | 8 | ||||
-rw-r--r-- | dev-go/go-tools/Manifest | 12 | ||||
-rw-r--r-- | dev-go/go-tools/go-tools-1.4.2_p20150520-r1.ebuild | 98 | ||||
-rw-r--r-- | dev-go/go-tools/go-tools-9999.ebuild | 19 |
4 files changed, 130 insertions, 7 deletions
diff --git a/dev-go/go-tools/ChangeLog b/dev-go/go-tools/ChangeLog index e074f85a7230..f87f2e98003d 100644 --- a/dev-go/go-tools/ChangeLog +++ b/dev-go/go-tools/ChangeLog @@ -1,6 +1,12 @@ # ChangeLog for dev-go/go-tools # Copyright 1999-2015 Gentoo Foundation; Distributed under the GPL v2 -# $Header: /var/cvsroot/gentoo-x86/dev-go/go-tools/ChangeLog,v 1.7 2015/05/28 07:11:30 zmedico Exp $ +# $Header: /var/cvsroot/gentoo-x86/dev-go/go-tools/ChangeLog,v 1.8 2015/06/03 07:05:58 zmedico Exp $ + +*go-tools-1.4.2_p20150520-r1 (03 Jun 2015) + + 03 Jun 2015; Zac Medico <zmedico@gentoo.org> + +go-tools-1.4.2_p20150520-r1.ebuild, go-tools-9999.ebuild: + Add favicon to the godoc web interface (bug 551030). 28 May 2015; Zac Medico <zmedico@gentoo.org> go-tools-1.4.2_p20150520.ebuild, go-tools-9999.ebuild: diff --git a/dev-go/go-tools/Manifest b/dev-go/go-tools/Manifest index 3eef0a2666d0..a19c0c3a6105 100644 --- a/dev-go/go-tools/Manifest +++ b/dev-go/go-tools/Manifest @@ -1,15 +1,17 @@ -----BEGIN PGP SIGNED MESSAGE----- Hash: SHA256 +DIST go-favicon.ico 1150 SHA256 d76ca702a6d81e20ddd31c8c5a4368130e7c68d990600316f6f1c9509bd38ba7 SHA512 194c4b3c360321a10f714b6755d9155de6129682b4070d19b52d0d5706fcbd1d244ea38c33fd77fe1dec85b3e39720dd0a62f5b126803036fbc8337a9d72fea6 WHIRLPOOL f55a84a28812bffd1fa38e098e6ba7d757bdefc0e20c3d8ef767fb1bc7d6e2cfbb8d1ae0593e81cce17c27f60e6aacf094e6c67b1f592c0546090feab9d3830f DIST go-tools-1.4.2_p20150520.tar.gz 1625986 SHA256 ea5cdf7c19b250c2e98b136ff993d1ecbfb66b052c7ac748a03f99eedf676f99 SHA512 1a3fd27fb79d449f876823f032f1a4a00bbb83cf8e9c370634910e76cdcb3c0e4b5fbad6b6012e928e82c7c986a1dadc60c49f2b6021730952725dc32e3cea3d WHIRLPOOL 641d95c9dccf7194a38ee767cb2cf54c91f676a271ef7113df2b05ffaeed7c2afeddd2a1ab005a80f035762cf502b57e336948cc55e1a7ab0d7b625779555183 +EBUILD go-tools-1.4.2_p20150520-r1.ebuild 3311 SHA256 399639e73124bb04a27e9d986a4732b6287819d8a6886fafe07861e73a942167 SHA512 366e423a2488b39e371b8cd1d5d5dc901c0257a98fa0a11c4cb285ba43bdbaaef075e654d4cbbbd2cbbf25cfd5c4b8da331dd4ebd3e326c9ffecb0f57314f583 WHIRLPOOL b8d952b14c0916f0ecf8c81628428855b0892d5fdf9186f146451e3d65cf3bdab049ac065029a59040d2dc7c5400b6e8525c0450fdfa4f9c9e04ca2d648e1d2d EBUILD go-tools-1.4.2_p20150520.ebuild 2743 SHA256 634d07682c68dfb6320193b77de5da52d2cbc67128b7e0bb8f25bf3070bba99b SHA512 f4a285a8200ebd23c7c131b3252c3360a3625e0fde7e86e2bc801e016b2bf1532064c6b21b9cd73212b53e63df24fa461bdc0f33fe6650a226910365d954ea32 WHIRLPOOL c2921af50469c2ecea0dec4a1ad271786ebe4a4490f38c30fc4282c1b83151b1eb1b65f882ad940eb0571ba63c174fa7d5ce0ced0e9209f9355ff802b738809c -EBUILD go-tools-9999.ebuild 2541 SHA256 0bcbc604427d44073dbe689ffa1d88b52a3ea14a5f9ce24332093e3f4eeb7cca SHA512 a41e30294c67d78a18e3fc256b47eefc394f15ace2693a017017bd0f655686dc9982c901bd984aaf92cf08724bb043c8bbec0bec6bdc1ef0bc2bc4cc1471ce85 WHIRLPOOL f4a5024b725a4e55af7276195966e008e899f4fed78ef3601dcb9f4b9a88eddd97b36c21241621c7476c4506e073f76d315b4acde980795e19742bbc6e0cb2b3 -MISC ChangeLog 1108 SHA256 023da5ee8b02fc10a9133ea2b5c3b2743d44e7e5b0178698b791991fad412b1e SHA512 a2ae3b4799abd9f3520269eadb33e4215db943a16f96efe768d29dbf9c095033be732f525e2384a7342226e7e1289e8b0aca5e878c6e20f9d5898badf492c7fa WHIRLPOOL 1f3a36d9601783d7a602a91c2ba2164cb294a49cfd2e6d2d47282845dfcee1fcebe987ea18729a55f6d6131807db10ac4278e1ebe85206ad6cab067c031e6d9a +EBUILD go-tools-9999.ebuild 3152 SHA256 243c4de54fb686285e8400cc9818999f2a6a9a7bbd9dd65639a62340083af9ca SHA512 c2179d66fb1f9848950238c7ac855db69de83db39574e3b5725c263694e3115258a4276e0c6881aa9bdc882ea6fbf1e2f8a69964f46b538efd7ef32d5feaa48f WHIRLPOOL 9c746b90f4a6287f1de8bdaa7637c0330fed6ad8075748702cc2b0f59f6a2bc2608fcfc43c8991be082ce0feae034bc7c7e9735dd9ce95f83e97901807f29113 +MISC ChangeLog 1316 SHA256 b9972d5b138cd777ac51d903c5587eca0d4edb25176c0d49d99809a3f543ac13 SHA512 b3e51a4d0f352dd190010bf72d84fe48eecb57c388ae2681e6c5d79959bce6f46240cc6e44574a7cab31b79afffbedbc77a1557a751c22279d1372858bd644c4 WHIRLPOOL d02dce814f51e98fa41d96a13d4b073f4918012ee72216a9a09eb3bf689cf3d930fcc9948ed5fbcddab532f4895cb1b66e9d7cac5f6a2fdb5a8e22966df1b511 MISC metadata.xml 208 SHA256 67f4cd233dc8d6d341b8da89aef2654cae64f7e3b62fbcdd3a35e6e30e898e36 SHA512 5213f6c100db04c6bbbf73b4e52042caf1744aa805af76053f5ecaf5f921ffdd35c41507b492da65c6071f1699472db6c9334dcd5bb7da752dca8efe7e1c7aa4 WHIRLPOOL a43dc0ecd7f37ba8cf4d510a1195338816b6193e5c5517c8e005662a06d7fb62c725a3c2981474a872cba628c268de1bea0fb67a31ae1842a252c0fdc723eb4d -----BEGIN PGP SIGNATURE----- Version: GnuPG v2 -iEYEAREIAAYFAlVmv6YACgkQ/ejvha5XGaNWIACfVFAMyVKsMdVlBHj1ypajJhOo -VRoAnAvuFzxIf8ozKiox3ktE4dxU0BMX -=nwg+ +iEYEAREIAAYFAlVup1cACgkQ/ejvha5XGaPTzQCfVTNvLjzKjbxWh1b/vdytgIz3 +sOwAoI0lOY1ls8NYfEz31evfQ/H2Pwgn +=OENl -----END PGP SIGNATURE----- diff --git a/dev-go/go-tools/go-tools-1.4.2_p20150520-r1.ebuild b/dev-go/go-tools/go-tools-1.4.2_p20150520-r1.ebuild new file mode 100644 index 000000000000..32522c175fa4 --- /dev/null +++ b/dev-go/go-tools/go-tools-1.4.2_p20150520-r1.ebuild @@ -0,0 +1,98 @@ +# Copyright 1999-2015 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: /var/cvsroot/gentoo-x86/dev-go/go-tools/go-tools-1.4.2_p20150520-r1.ebuild,v 1.1 2015/06/03 07:05:58 zmedico Exp $ + +EAPI=5 + +KEYWORDS="~amd64" +DESCRIPTION="Go Tools" +MY_PN=${PN##*-} +GO_PN=golang.org/x/${MY_PN} +HOMEPAGE="https://godoc.org/${GO_PN}" +EGIT_COMMIT="3d1847243ea4f07666a91110f48e79e43396603d" +SRC_URI="https://github.com/golang/${MY_PN}/archive/${EGIT_COMMIT}.tar.gz -> ${P}.tar.gz + http://golang.org/favicon.ico -> go-favicon.ico" +LICENSE="BSD" +SLOT="0" +IUSE="" +DEPEND=">=dev-lang/go-1.4 + dev-go/go-net" +RDEPEND="" +S="${WORKDIR}/src/${GO_PN}" +EGIT_CHECKOUT_DIR="${S}" +STRIP_MASK="*.a" + +src_unpack() { + default + mkdir -p src/${GO_PN%/*} || die + mv ${MY_PN}-${EGIT_COMMIT} src/${GO_PN} || die + cp "${DISTDIR}"/go-favicon.ico "${S}"/godoc/static/favicon.ico || die +} + +src_prepare() { + # disable broken tests + sed -e 's:TestWeb(:_\0:' -i cmd/godoc/godoc_test.go || die + sed -e 's:TestVet(:_\0:' -i cmd/vet/vet_test.go || die + sed -e 's:TestImport(:_\0:' -i go/gcimporter/gcimporter_test.go || die + sed -e 's:TestImportStdLib(:_\0:' -i go/importer/import_test.go || die + sed -e 's:TestStdlib(:_\0:' -i go/loader/stdlib_test.go || die + sed -e 's:TestStdlib(:_\0:' -i go/ssa/stdlib_test.go || die + sed -e 's:TestGorootTest(:_\0:' \ + -e 's:TestFoo(:_\0:' \ + -e 's:TestTestmainPackage(:_\0:' \ + -i go/ssa/interp/interp_test.go || die + sed -e 's:TestBar(:_\0:' \ + -e 's:TestFoo(:_\0:' -i go/ssa/interp/testdata/a_test.go || die + sed -e 's:TestCheck(:_\0:' -i go/types/check_test.go || die + sed -e 's:TestStdlib(:_\0:' \ + -e 's:TestStdFixed(:_\0:' \ + -e 's:TestStdKen(:_\0:' -i go/types/stdlib_test.go || die + sed -e 's:TestRepoRootForImportPath(:_\0:' -i go/vcs/vcs_test.go || die + sed -e 's:TestStdlib(:_\0:' -i refactor/lexical/lexical_test.go || die + + # Add favicon to the godoc web interface (bug 551030) + sed -e 's:"example.html",:\0\n\t"favicon.ico",:' -i godoc/static/makestatic.go || die + sed -e 's:<link type="text/css":<link rel="icon" type="image/png" href="/lib/godoc/favicon.ico">\n\0:' -i \ + godoc/static/godoc.html || die +} + +src_compile() { + # Create a writable GOROOT in order to avoid sandbox violations. + GOROOT="${WORKDIR}/goroot" + cp -sR "${EPREFIX}"/usr/lib/go "${GOROOT}" || die + rm -rf "${GOROOT}/src/${GO_PN}" \ + "${GOROOT}/pkg/linux_${ARCH}/${GO_PN}" || die + + # Generate static.go with favicon included + pushd godoc/static >/dev/null + GOROOT="${GOROOT}" GOPATH=${WORKDIR} go run makestatic.go || die + popd >/dev/null + + GOROOT="${GOROOT}" GOPATH=${WORKDIR} go install -v -x -work ${GO_PN}/... || die +} + +src_test() { + GOROOT="${GOROOT}" GOPATH=${WORKDIR} \ + go test -x -v ${GO_PN}/... || die $? +} + +src_install() { + local x + exeinto /usr/lib/go/bin + doexe "${WORKDIR}"/bin/* + + # godoc ends up in ${GOROOT}/bin + dodir /usr/bin + while read -r -d '' x; do + doexe "${x}" + ln "${ED}"usr/{lib/go/bin,bin}/${x##*/} || die + done < <(find "${GOROOT}/bin" -type f -print0) + + # cover and vet end up in ${GOROOT}/pkg/tool/linux_amd64 + exeinto /usr/lib/go/pkg/tool/linux_amd64 + find "${GOROOT}/pkg/tool/linux_amd64" -type f -exec doexe {} \; + + insinto /usr/lib/go + find "${WORKDIR}"/{pkg,src} -name '.git*' -exec rm -rf {} \; 2>/dev/null + doins -r "${WORKDIR}"/{pkg,src} +} diff --git a/dev-go/go-tools/go-tools-9999.ebuild b/dev-go/go-tools/go-tools-9999.ebuild index ab51ec114fa8..3496e6c4875c 100644 --- a/dev-go/go-tools/go-tools-9999.ebuild +++ b/dev-go/go-tools/go-tools-9999.ebuild @@ -1,6 +1,6 @@ # Copyright 1999-2015 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo-x86/dev-go/go-tools/go-tools-9999.ebuild,v 1.5 2015/05/28 07:11:30 zmedico Exp $ +# $Header: /var/cvsroot/gentoo-x86/dev-go/go-tools/go-tools-9999.ebuild,v 1.6 2015/06/03 07:05:58 zmedico Exp $ EAPI=5 inherit git-r3 @@ -11,6 +11,7 @@ MY_PN=${PN##*-} GO_PN=golang.org/x/${MY_PN} HOMEPAGE="https://godoc.org/${GO_PN}" EGIT_REPO_URI="https://go.googlesource.com/${MY_PN}" +SRC_URI="http://golang.org/favicon.ico -> go-favicon.ico" LICENSE="BSD" SLOT="0" IUSE="" @@ -21,6 +22,11 @@ S="${WORKDIR}/src/${GO_PN}" EGIT_CHECKOUT_DIR="${S}" STRIP_MASK="*.a" +src_unpack() { + git-r3_src_unpack + cp "${DISTDIR}"/go-favicon.ico "${S}"/godoc/static/favicon.ico || die +} + src_prepare() { # disable broken tests sed -e 's:TestWeb(:_\0:' -i cmd/godoc/godoc_test.go || die @@ -41,6 +47,11 @@ src_prepare() { -e 's:TestStdKen(:_\0:' -i go/types/stdlib_test.go || die sed -e 's:TestRepoRootForImportPath(:_\0:' -i go/vcs/vcs_test.go || die sed -e 's:TestStdlib(:_\0:' -i refactor/lexical/lexical_test.go || die + + # Add favicon to the godoc web interface (bug 551030) + sed -e 's:"example.html",:\0\n\t"favicon.ico",:' -i godoc/static/makestatic.go || die + sed -e 's:<link type="text/css":<link rel="icon" type="image/png" href="/lib/godoc/favicon.ico">\n\0:' -i \ + godoc/static/godoc.html || die } src_compile() { @@ -49,6 +60,12 @@ src_compile() { cp -sR "${EPREFIX}"/usr/lib/go "${GOROOT}" || die rm -rf "${GOROOT}/src/${GO_PN}" \ "${GOROOT}/pkg/linux_${ARCH}/${GO_PN}" || die + + # Generate static.go with favicon included + pushd godoc/static >/dev/null + GOROOT="${GOROOT}" GOPATH=${WORKDIR} go run makestatic.go || die + popd >/dev/null + GOROOT="${GOROOT}" GOPATH=${WORKDIR} go install -v -x -work ${GO_PN}/... || die } |