1 |
commit: ef42bcbc1634a4d30a3f05f7b102782a52baac1e |
2 |
Author: William Hubbs <williamh <AT> gentoo <DOT> org> |
3 |
AuthorDate: Sun Nov 29 19:19:03 2015 +0000 |
4 |
Commit: William Hubbs <williamh <AT> gentoo <DOT> org> |
5 |
CommitDate: Sun Nov 29 19:19:03 2015 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=ef42bcbc |
7 |
|
8 |
dev-lang/go: remove old unstable version |
9 |
|
10 |
dev-lang/go/go-1.5.1.ebuild | 211 -------------------------------------------- |
11 |
1 file changed, 211 deletions(-) |
12 |
|
13 |
diff --git a/dev-lang/go/go-1.5.1.ebuild b/dev-lang/go/go-1.5.1.ebuild |
14 |
deleted file mode 100644 |
15 |
index a69f787..0000000 |
16 |
--- a/dev-lang/go/go-1.5.1.ebuild |
17 |
+++ /dev/null |
18 |
@@ -1,211 +0,0 @@ |
19 |
-# Copyright 1999-2015 Gentoo Foundation |
20 |
-# Distributed under the terms of the GNU General Public License v2 |
21 |
-# $Id$ |
22 |
- |
23 |
-EAPI=5 |
24 |
- |
25 |
-export CBUILD=${CBUILD:-${CHOST}} |
26 |
-export CTARGET=${CTARGET:-${CHOST}} |
27 |
- |
28 |
-inherit eutils toolchain-funcs |
29 |
- |
30 |
-if [[ ${PV} = 9999 ]]; then |
31 |
- EGIT_REPO_URI="git://github.com/golang/go.git" |
32 |
- inherit git-r3 |
33 |
-else |
34 |
- SRC_URI="https://storage.googleapis.com/golang/go${PV}.src.tar.gz" |
35 |
- # go-bootstrap-1.4 only supports go on amd64, arm and x86 architectures. |
36 |
- # Allowing other bootstrap options would enable arm64 and ppc64 builds. |
37 |
- KEYWORDS="-* ~amd64 ~arm ~x86 ~amd64-fbsd ~x86-fbsd ~x64-macos ~x86-macos" |
38 |
-fi |
39 |
- |
40 |
-DESCRIPTION="A concurrent garbage collected and typesafe programming language" |
41 |
-HOMEPAGE="http://www.golang.org" |
42 |
- |
43 |
-LICENSE="BSD" |
44 |
-SLOT="0/${PV}" |
45 |
-IUSE="" |
46 |
- |
47 |
-DEPEND=">=dev-lang/go-bootstrap-1.4.1" |
48 |
-RDEPEND="!<dev-go/go-tools-0_pre20150902" |
49 |
- |
50 |
-# These test data objects have writable/executable stacks. |
51 |
-QA_EXECSTACK="usr/lib/go/src/debug/elf/testdata/*.obj" |
52 |
- |
53 |
-REQUIRES_EXCLUDE="/usr/lib/go/src/debug/elf/testdata/*" |
54 |
- |
55 |
-# The tools in /usr/lib/go should not cause the multilib-strict check to fail. |
56 |
-QA_MULTILIB_PATHS="usr/lib/go/pkg/tool/.*/.*" |
57 |
- |
58 |
-# The go language uses *.a files which are _NOT_ libraries and should not be |
59 |
-# stripped. The test data objects should also be left alone and unstripped. |
60 |
-STRIP_MASK="/usr/lib/go/pkg/*.a |
61 |
- /usr/lib/go/src/debug/elf/testdata/* |
62 |
- /usr/lib/go/src/debug/dwarf/testdata/* |
63 |
- /usr/lib/go/src/runtime/race/*.syso" |
64 |
- |
65 |
-if [[ ${PV} != 9999 ]]; then |
66 |
- S="${WORKDIR}"/go |
67 |
-fi |
68 |
- |
69 |
-go_arch() |
70 |
-{ |
71 |
- # By chance most portage arch names match Go |
72 |
- local portage_arch=$(tc-arch $@) |
73 |
- case "${portage_arch}" in |
74 |
- x86) echo 386;; |
75 |
- x64-*) echo amd64;; |
76 |
- *) echo "${portage_arch}";; |
77 |
- esac |
78 |
-} |
79 |
- |
80 |
-go_arm() |
81 |
-{ |
82 |
- case "${1:-${CHOST}}" in |
83 |
- armv5*) echo 5;; |
84 |
- armv6*) echo 6;; |
85 |
- armv7*) echo 7;; |
86 |
- *) |
87 |
- die "unknown GOARM for ${1:-${CHOST}}" |
88 |
- ;; |
89 |
- esac |
90 |
-} |
91 |
- |
92 |
-go_os() |
93 |
-{ |
94 |
- case "${1:-${CHOST}}" in |
95 |
- *-linux*) echo linux;; |
96 |
- *-darwin*) echo darwin;; |
97 |
- *-freebsd*) echo freebsd;; |
98 |
- *-netbsd*) echo netbsd;; |
99 |
- *-openbsd*) echo openbsd;; |
100 |
- *-solaris*) echo solaris;; |
101 |
- *-cygwin*|*-interix*|*-winnt*) |
102 |
- echo windows |
103 |
- ;; |
104 |
- *) |
105 |
- die "unknown GOOS for ${1:-${CHOST}}" |
106 |
- ;; |
107 |
- esac |
108 |
-} |
109 |
- |
110 |
-go_tuple() |
111 |
-{ |
112 |
- echo "$(go_os $@)_$(go_arch $@)" |
113 |
-} |
114 |
- |
115 |
-go_cross_compile() |
116 |
-{ |
117 |
- [[ $(go_tuple ${CBUILD}) != $(go_tuple) ]] |
118 |
-} |
119 |
- |
120 |
-pkg_pretend() |
121 |
-{ |
122 |
- # make.bash does not understand cross-compiling a cross-compiler |
123 |
- if [[ $(go_tuple) != $(go_tuple ${CTARGET}) ]]; then |
124 |
- die "CHOST CTARGET pair unsupported: CHOST=${CHOST} CTARGET=${CTARGET}" |
125 |
- fi |
126 |
-} |
127 |
- |
128 |
-src_prepare() |
129 |
-{ |
130 |
- if [[ ${PV} != 9999 ]]; then |
131 |
- sed -i -e 's/"-Werror",//g' src/cmd/dist/build.go || |
132 |
- die 'sed failed' |
133 |
- fi |
134 |
- epatch_user |
135 |
-} |
136 |
- |
137 |
-src_compile() |
138 |
-{ |
139 |
- export GOROOT_BOOTSTRAP="${EPREFIX}"/usr/lib/go1.4 |
140 |
- export GOROOT_FINAL="${EPREFIX}"/usr/lib/go |
141 |
- export GOROOT="$(pwd)" |
142 |
- export GOBIN="${GOROOT}/bin" |
143 |
- |
144 |
- # Go's build script does not use BUILD/HOST/TARGET consistently. :( |
145 |
- export GOHOSTARCH=$(go_arch ${CBUILD}) |
146 |
- export GOHOSTOS=$(go_os ${CBUILD}) |
147 |
- export CC=$(tc-getBUILD_CC) |
148 |
- |
149 |
- export GOARCH=$(go_arch) |
150 |
- export GOOS=$(go_os) |
151 |
- export CC_FOR_TARGET=$(tc-getCC) |
152 |
- export CXX_FOR_TARGET=$(tc-getCXX) |
153 |
- if [[ ${ARCH} == arm ]]; then |
154 |
- export GOARM=$(go_arm) |
155 |
- fi |
156 |
- |
157 |
- cd src |
158 |
- ./make.bash || die "build failed" |
159 |
-} |
160 |
- |
161 |
-src_test() |
162 |
-{ |
163 |
- go_cross_compile && return 0 |
164 |
- |
165 |
- cd src |
166 |
- PATH="${GOBIN}:${PATH}" \ |
167 |
- ./run.bash -no-rebuild || die "tests failed" |
168 |
-} |
169 |
- |
170 |
-src_install() |
171 |
-{ |
172 |
- local bin_path="${GOBIN}" |
173 |
- if go_cross_compile; then |
174 |
- bin_path="${GOBIN}/$(go_tuple)" |
175 |
- fi |
176 |
- dobin "${bin_path}"/* |
177 |
- dodoc AUTHORS CONTRIBUTORS PATENTS README.md |
178 |
- |
179 |
- dodir /usr/lib/go /usr/lib/go/pkg /usr/lib/go/pkg/tool |
180 |
- insinto /usr/lib/go |
181 |
- |
182 |
- # There is a known issue which requires the source tree to be installed [1]. |
183 |
- # Once this is fixed, we can consider using the doc use flag to control |
184 |
- # installing the doc and src directories. |
185 |
- # [1] https://golang.org/issue/2775 |
186 |
- doins -r doc lib src |
187 |
- |
188 |
- # Selectively install pkg directory to exclude the bootstrap build |
189 |
- insinto /usr/lib/go/pkg |
190 |
- doins -r pkg/include "pkg/$(go_tuple)" |
191 |
- insinto /usr/lib/go/pkg/tool |
192 |
- doins -r "pkg/tool/$(go_tuple)" |
193 |
- fperms -R +x /usr/lib/go/pkg/tool |
194 |
-} |
195 |
- |
196 |
-pkg_preinst() |
197 |
-{ |
198 |
- has_version '<dev-lang/go-1.4' && |
199 |
- export had_support_files=true || |
200 |
- export had_support_files=false |
201 |
-} |
202 |
- |
203 |
-pkg_postinst() |
204 |
-{ |
205 |
- # If the go tool sees a package file timestamped older than a dependancy it |
206 |
- # will rebuild that file. So, in order to stop go from rebuilding lots of |
207 |
- # packages for every build we need to fix the timestamps. The compiler and |
208 |
- # linker are also checked - so we need to fix them too. |
209 |
- ebegin "fixing timestamps to avoid unnecessary rebuilds" |
210 |
- tref="usr/lib/go/pkg/*/runtime.a" |
211 |
- find "${EROOT}"usr/lib/go -type f \ |
212 |
- -exec touch -r "${EROOT}"${tref} {} \; |
213 |
- eend $? |
214 |
- |
215 |
- if [[ ${PV} != 9999 && -n ${REPLACING_VERSIONS} && |
216 |
- ${REPLACING_VERSIONS} != ${PV} ]]; then |
217 |
- elog "Release notes are located at http://golang.org/doc/go${PV}" |
218 |
- fi |
219 |
- |
220 |
- if $had_support_files; then |
221 |
- ewarn |
222 |
- ewarn "All editor support, IDE support, shell completion" |
223 |
- ewarn "support, etc has been removed from the go package" |
224 |
- ewarn "upstream." |
225 |
- ewarn "For more information on which support is available, see" |
226 |
- ewarn "the following URL:" |
227 |
- ewarn "https://github.com/golang/go/wiki/IDEsAndTextEditorPlugins" |
228 |
- fi |
229 |
-} |