1 |
commit: e1128a3c0ff11292e9a62b831b2f8c46d29ba194 |
2 |
Author: William Hubbs <william.hubbs <AT> sony <DOT> com> |
3 |
AuthorDate: Fri Sep 6 13:13:33 2019 +0000 |
4 |
Commit: William Hubbs <williamh <AT> gentoo <DOT> org> |
5 |
CommitDate: Fri Sep 6 13:14:42 2019 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=e1128a3c |
7 |
|
8 |
dev-lang/go: remove 1.11 |
9 |
|
10 |
Copyright: Sony Interactive Entertainment Inc. |
11 |
Package-Manager: Portage-2.3.69, Repoman-2.3.16 |
12 |
Signed-off-by: William Hubbs <williamh <AT> gentoo.org> |
13 |
|
14 |
dev-lang/go/Manifest | 3 - |
15 |
dev-lang/go/go-1.11.10.ebuild | 246 ------------------------------------------ |
16 |
dev-lang/go/go-1.11.12.ebuild | 246 ------------------------------------------ |
17 |
dev-lang/go/go-1.11.13.ebuild | 246 ------------------------------------------ |
18 |
4 files changed, 741 deletions(-) |
19 |
|
20 |
diff --git a/dev-lang/go/Manifest b/dev-lang/go/Manifest |
21 |
index ec16524f2e4..fb69d657355 100644 |
22 |
--- a/dev-lang/go/Manifest |
23 |
+++ b/dev-lang/go/Manifest |
24 |
@@ -9,9 +9,6 @@ DIST go-linux-ppc64-bootstrap-1.8.tbz 52315782 BLAKE2B 6be0a48e8bc4e5fed4d34f8aa |
25 |
DIST go-linux-ppc64le-bootstrap-1.8.tbz 52211575 BLAKE2B 7a28ec5a381369c4e9415c8360e904c2545380513afd328077c584e8af0bf6bd818aa03e5a58c350cbb98facc1c9dccb02b06adcb27233875497cf5d33265912 SHA512 6931d999dd0ee1ff44c4cec48acb27af061f57f87aa74802dcebab78553b46bc8ac732f07fe91e5074dbdd32c55b707994875934bfb12bb4276d71eb1d06c4ba |
26 |
DIST go-linux-s390x-bootstrap-1.8.tbz 57124869 BLAKE2B 920a176b8f4fc3a816e724324bbb30a383d599e31a0d2093d24797dbcd0e799a662a3589dbb87d2f5dd16df07c4cf8f1e444e87b540ec732746bb025dc9271f8 SHA512 d429cae870d66217ab2e07c74209d3031d97baa4f899b4d70ae6283a1a5b1434b037904c4cfca0b2bc798d5ba0b358c3739e000eccbc74809baf564c5686df5a |
27 |
DIST go-solaris-amd64-bootstrap-1.8.tbz 54926326 BLAKE2B 0a45312f090d81ebf46fe5950cb65c059e2801394231e715e94145d1f918eb59b10472b2385e57ebd5cfb9eca0ad7290fb118436486b665520bb540970f971ab SHA512 52b849e5b9a940e10de7ba3df0ebdf6e1c5d631de9581d936c9edf8f38e6bb3314acbc2b2d5202b0528fde2a359d52bc0c6f39acf9b1b614725e4b4a947ed10d |
28 |
-DIST go1.11.10.src.tar.gz 21113259 BLAKE2B 2dc704ea092fb4f4bb6c379ecb5104eb9dc5657750fb046810f210f38191d494c926e7a3661f67ea09c3d4090676485ba346daaa6dfe9eebbf3d69acbacea3b8 SHA512 8fab3b96d1c47b8f75b135da9d1a104c485098f6f42041b69336216a57cfd49c0785c8cfa7b016020ded5f0aadd279d7a76feeca33038321a4930139aee28cc8 |
29 |
-DIST go1.11.12.src.tar.gz 21113396 BLAKE2B ef5cca83a0118faa4e4e8d417d629eab0f01a9e16c47851f1d92df07fd7ef0ec0ea790d0fd190fa9a66c86acab619f1436840e52b7890b8ef9b8fe7335307a45 SHA512 ff74678d7002be20c994702cc778d2447bbe4aad2ecf906e4cde9cf00c0c226c2f0def25146acd24f86fddf397b47602c1e5509c21b0d7b856cf933a05e19a6d |
30 |
-DIST go1.11.13.src.tar.gz 21114296 BLAKE2B 0f1139a3bfd8e84bc7a150d888dbdb0268e301234ae96f49d9d657d7d92360ad1b54177c066654ce5bf3e923bbda0ee35a3265284086e820c1476705f348fc17 SHA512 a5dc8ec2bdad226e2498fdfb3560d6e7e19a84711cc1adb91675a8563a0b1fd153513397ca2a2b8cf266d718a6964ad143dfa588313dcf7fe350dd4a24efc3e9 |
31 |
DIST go1.12.5.src.tar.gz 21971348 BLAKE2B 7de8db4a6c4cd9e1883fbf28357fe99ad9f43f3e015b2063347b1961df128760b720c0dd5549997c7080e6cf0036406430419d4bf033323f26017d3629ad6067 SHA512 ce64105ff71615f9d235cc7c8656b6409fc40cc90d15a28d355fadd9072d2eab842af379dd8bba0f1181715753143e4a07491e0f9e5f8df806327d7c95a34fae |
32 |
DIST go1.12.6.src.tar.gz 21975398 BLAKE2B 05c183baf2e6544b039cff33abb7c5d66a50a0a7cadaa16032a3dc3793bfa27e82c4598dbb700bf7f90ba2ce2639bb60484e61e50fc154d8184d4874954b81e4 SHA512 431a0b916ce2e64d816808a04bc3bf028e955538ab55c571021c08e599781ae344487a55e119bb3aae3d32f84cd83e2c176dc72d336b95da0352edffeab07a48 |
33 |
DIST go1.12.7.src.tar.gz 21976647 BLAKE2B bf0c723f1e02048d91844c7b8908500c83442a8ab7ceeaacdb37d7204f72d80331eab44de54f99411479be8e645b2626fb8a34df0cedbd75fa57c4e1d84d493a SHA512 f84c6b89dea9df21f0efa07564eb80baeee5bc2d68cced5fd645ebb32e9317e60b657afe011c81e7739d8a93e4b4dafa0b4f78431a009d36e05de55f89ed0fd6 |
34 |
|
35 |
diff --git a/dev-lang/go/go-1.11.10.ebuild b/dev-lang/go/go-1.11.10.ebuild |
36 |
deleted file mode 100644 |
37 |
index b48fe53d64d..00000000000 |
38 |
--- a/dev-lang/go/go-1.11.10.ebuild |
39 |
+++ /dev/null |
40 |
@@ -1,246 +0,0 @@ |
41 |
-# Copyright 1999-2019 Gentoo Authors |
42 |
-# Distributed under the terms of the GNU General Public License v2 |
43 |
- |
44 |
-EAPI=7 |
45 |
- |
46 |
-export CBUILD=${CBUILD:-${CHOST}} |
47 |
-export CTARGET=${CTARGET:-${CHOST}} |
48 |
- |
49 |
-MY_PV=${PV/_/} |
50 |
- |
51 |
-inherit toolchain-funcs |
52 |
- |
53 |
-BOOTSTRAP_VERSION="bootstrap-1.8" |
54 |
-BOOTSTRAP_DIST="https://dev.gentoo.org/~williamh/dist" |
55 |
-BOOTSTRAP_URI=" |
56 |
- ${BOOTSTRAP_DIST}/go-linux-amd64-${BOOTSTRAP_VERSION}.tbz |
57 |
- ${BOOTSTRAP_DIST}/go-linux-arm-${BOOTSTRAP_VERSION}.tbz |
58 |
- ${BOOTSTRAP_DIST}/go-linux-arm64-${BOOTSTRAP_VERSION}.tbz |
59 |
- ${BOOTSTRAP_DIST}/go-linux-ppc64-${BOOTSTRAP_VERSION}.tbz |
60 |
- ${BOOTSTRAP_DIST}/go-linux-ppc64le-${BOOTSTRAP_VERSION}.tbz |
61 |
- ${BOOTSTRAP_DIST}/go-linux-s390x-${BOOTSTRAP_VERSION}.tbz |
62 |
- ${BOOTSTRAP_DIST}/go-linux-386-${BOOTSTRAP_VERSION}.tbz |
63 |
- ${BOOTSTRAP_DIST}/go-freebsd-amd64-${BOOTSTRAP_VERSION}.tbz |
64 |
- ${BOOTSTRAP_DIST}/go-freebsd-386-${BOOTSTRAP_VERSION}.tbz |
65 |
- ${BOOTSTRAP_DIST}/go-darwin-amd64-${BOOTSTRAP_VERSION}.tbz |
66 |
- ${BOOTSTRAP_DIST}/go-solaris-amd64-${BOOTSTRAP_VERSION}.tbz |
67 |
-" |
68 |
- |
69 |
-case ${PV} in |
70 |
-*9999*) |
71 |
- EGIT_REPO_URI="https://github.com/golang/go.git" |
72 |
- inherit git-r3 |
73 |
- ;; |
74 |
-*) |
75 |
- SRC_URI="https://storage.googleapis.com/golang/go${MY_PV}.src.tar.gz " |
76 |
- S="${WORKDIR}"/go |
77 |
- case ${PV} in |
78 |
- *_beta*|*_rc*) ;; |
79 |
- *) |
80 |
- KEYWORDS="-* amd64 arm ~arm64 ~ppc64 ~s390 x86 ~amd64-fbsd ~x86-fbsd ~amd64-linux ~x64-macos ~x64-solaris" |
81 |
- # The upstream tests fail under portage but pass if the build is |
82 |
- # run according to their documentation [1]. |
83 |
- # I am restricting the tests on released versions until this is |
84 |
- # solved. |
85 |
- # [1] https://golang.org/issues/18442 |
86 |
- RESTRICT="test" |
87 |
- ;; |
88 |
- esac |
89 |
-esac |
90 |
- |
91 |
-# If gccgo or a previously installed version of dev-lang/go is not being |
92 |
-# used to build Go, there is no way to know the architecture or operating system |
93 |
-# of the build machine, so we need to download all of our bootstrap |
94 |
-# archives to allow this ebuild to work under crossdev. |
95 |
-# |
96 |
-# https://bugs.gentoo.org/671394 |
97 |
-SRC_URI+="!gccgo? ( !system-bootstrap? ( ${BOOTSTRAP_URI} ) )" |
98 |
- |
99 |
-DESCRIPTION="A concurrent garbage collected and typesafe programming language" |
100 |
-HOMEPAGE="https://golang.org" |
101 |
- |
102 |
-LICENSE="BSD" |
103 |
-SLOT="0/${PV}" |
104 |
-IUSE="gccgo system-bootstrap" |
105 |
- |
106 |
-BDEPEND="gccgo? ( >=sys-devel/gcc-5[go] )" |
107 |
-RDEPEND="!<dev-go/go-tools-0_pre20150902" |
108 |
- |
109 |
-# These test data objects have writable/executable stacks. |
110 |
-QA_EXECSTACK=" |
111 |
- usr/lib/go/src/debug/elf/testdata/*.obj |
112 |
- usr/lib/go/src/*.gox |
113 |
- " |
114 |
- |
115 |
-# Do not complain about CFLAGS, etc, since Go doesn't use them. |
116 |
-QA_FLAGS_IGNORED='.*' |
117 |
- |
118 |
-REQUIRES_EXCLUDE="/usr/lib/go/src/debug/elf/testdata/*" |
119 |
- |
120 |
-# The tools in /usr/lib/go should not cause the multilib-strict check to fail. |
121 |
-QA_MULTILIB_PATHS="usr/lib/go/pkg/tool/.*/.*" |
122 |
- |
123 |
-# Do not strip this package. Stripping is unsupported upstream and may |
124 |
-# fail. |
125 |
-RESTRICT+=" strip" |
126 |
- |
127 |
-DOCS=( |
128 |
-AUTHORS |
129 |
-CONTRIBUTING.md |
130 |
-CONTRIBUTORS |
131 |
-PATENTS |
132 |
-README.md |
133 |
-) |
134 |
- |
135 |
-go_arch() |
136 |
-{ |
137 |
- # By chance most portage arch names match Go |
138 |
- local portage_arch=$(tc-arch $@) |
139 |
- case "${portage_arch}" in |
140 |
- x86) echo 386;; |
141 |
- x64-*) echo amd64;; |
142 |
- ppc64) [[ $(tc-endian $@) = big ]] && echo ppc64 || echo ppc64le ;; |
143 |
- s390) echo s390x ;; |
144 |
- *) echo "${portage_arch}";; |
145 |
- esac |
146 |
-} |
147 |
- |
148 |
-go_arm() |
149 |
-{ |
150 |
- case "${1:-${CHOST}}" in |
151 |
- armv5*) echo 5;; |
152 |
- armv6*) echo 6;; |
153 |
- armv7*) echo 7;; |
154 |
- *) |
155 |
- die "unknown GOARM for ${1:-${CHOST}}" |
156 |
- ;; |
157 |
- esac |
158 |
-} |
159 |
- |
160 |
-go_os() |
161 |
-{ |
162 |
- case "${1:-${CHOST}}" in |
163 |
- *-linux*) echo linux;; |
164 |
- *-darwin*) echo darwin;; |
165 |
- *-freebsd*) echo freebsd;; |
166 |
- *-netbsd*) echo netbsd;; |
167 |
- *-openbsd*) echo openbsd;; |
168 |
- *-solaris*) echo solaris;; |
169 |
- *-cygwin*|*-interix*|*-winnt*) |
170 |
- echo windows |
171 |
- ;; |
172 |
- *) |
173 |
- die "unknown GOOS for ${1:-${CHOST}}" |
174 |
- ;; |
175 |
- esac |
176 |
-} |
177 |
- |
178 |
-go_tuple() |
179 |
-{ |
180 |
- echo "$(go_os $@)_$(go_arch $@)" |
181 |
-} |
182 |
- |
183 |
-go_cross_compile() |
184 |
-{ |
185 |
- [[ $(go_tuple ${CBUILD}) != $(go_tuple) ]] |
186 |
-} |
187 |
- |
188 |
-pkg_pretend() |
189 |
-{ |
190 |
- # make.bash does not understand cross-compiling a cross-compiler |
191 |
- if [[ $(go_tuple) != $(go_tuple ${CTARGET}) ]]; then |
192 |
- die "CHOST CTARGET pair unsupported: CHOST=${CHOST} CTARGET=${CTARGET}" |
193 |
- fi |
194 |
- [[ ${MERGE_TYPE} != binary ]] && |
195 |
- use system-bootstrap && ! has_version "dev-lang/go" && |
196 |
- die "dev-lang/go must be installed to use the system-bootstrap use flag" |
197 |
-} |
198 |
- |
199 |
-src_unpack() |
200 |
-{ |
201 |
- if [[ ${PV} = 9999 ]]; then |
202 |
- git-r3_src_unpack |
203 |
- else |
204 |
- unpack "go${MY_PV}.src.tar.gz" |
205 |
- fi |
206 |
- use gccgo || use system-bootstrap || |
207 |
- unpack "go-$(go_os ${CBUILD})-$(go_arch ${CBUILD})-${BOOTSTRAP_VERSION}.tbz" |
208 |
-} |
209 |
- |
210 |
-src_compile() |
211 |
-{ |
212 |
- export GOROOT_BOOTSTRAP="${WORKDIR}"/go-$(go_os ${CBUILD})-$(go_arch ${CBUILD})-bootstrap |
213 |
- if use gccgo; then |
214 |
- mkdir -p "${GOROOT_BOOTSTRAP}/bin" || die |
215 |
- local go_binary=$(gcc-config --get-bin-path)/go-$(gcc-major-version) |
216 |
- [[ -x ${go_binary} ]] || go_binary=$( |
217 |
- find "${EPREFIX}"/usr/${CHOST}/gcc-bin/*/go-$(gcc-major-version) | |
218 |
- sort -V | tail -n1) |
219 |
- [[ -x ${go_binary} ]] || |
220 |
- die "go-$(gcc-major-version): command not found" |
221 |
- ln -s "${go_binary}" "${GOROOT_BOOTSTRAP}/bin/go" || die |
222 |
- elif use system-bootstrap; then |
223 |
- export GOROOT_BOOTSTRAP="${EPREFIX}"/usr/lib/go |
224 |
- fi |
225 |
- export GOROOT_FINAL="${EPREFIX}"/usr/lib/go |
226 |
- export GOROOT="$(pwd)" |
227 |
- export GOBIN="${GOROOT}/bin" |
228 |
- |
229 |
- # Go's build script does not use BUILD/HOST/TARGET consistently. :( |
230 |
- export GOHOSTARCH=$(go_arch ${CBUILD}) |
231 |
- export GOHOSTOS=$(go_os ${CBUILD}) |
232 |
- export CC=$(tc-getBUILD_CC) |
233 |
- |
234 |
- export GOARCH=$(go_arch) |
235 |
- export GOOS=$(go_os) |
236 |
- export CC_FOR_TARGET=$(tc-getCC) |
237 |
- export CXX_FOR_TARGET=$(tc-getCXX) |
238 |
- if [[ ${ARCH} == arm ]]; then |
239 |
- export GOARM=$(go_arm) |
240 |
- fi |
241 |
- |
242 |
- cd src |
243 |
- ./make.bash || die "build failed" |
244 |
-} |
245 |
- |
246 |
-src_test() |
247 |
-{ |
248 |
- go_cross_compile && return 0 |
249 |
- |
250 |
- cd src |
251 |
- PATH="${GOBIN}:${PATH}" \ |
252 |
- ./run.bash -no-rebuild || die "tests failed" |
253 |
-} |
254 |
- |
255 |
-src_install() |
256 |
-{ |
257 |
- local bin_path f x |
258 |
- |
259 |
- dodir /usr/lib/go |
260 |
- |
261 |
- # There is a known issue which requires the source tree to be installed [1]. |
262 |
- # Once this is fixed, we can consider using the doc use flag to control |
263 |
- # installing the doc and src directories. |
264 |
- # [1] https://golang.org/issue/2775 |
265 |
- # |
266 |
- # deliberately use cp to retain permissions |
267 |
- cp -R api bin doc lib pkg misc src test "${ED}"/usr/lib/go |
268 |
- if go_cross_compile; then |
269 |
- bin_path="bin/$(go_tuple)" |
270 |
- else |
271 |
- bin_path=bin |
272 |
- fi |
273 |
- for x in ${bin_path}/*; do |
274 |
- f=${x##*/} |
275 |
- dosym ../lib/go/${bin_path}/${f} /usr/bin/${f} |
276 |
- done |
277 |
- einstalldocs |
278 |
- |
279 |
- if [[ ${CHOST} == *-darwin* ]] ; then |
280 |
- # fix install_name for test object (binutils_test) on Darwin, it |
281 |
- # is never used in real circumstances |
282 |
- local libmac64="${EPREFIX}"/usr/lib/go/src/cmd/vendor/github.com/ |
283 |
- libmac64+=google/pprof/internal/binutils/testdata/lib_mac_64 |
284 |
- install_name_tool -id "${libmac64}" "${D}${libmac64}" |
285 |
- fi |
286 |
-} |
287 |
|
288 |
diff --git a/dev-lang/go/go-1.11.12.ebuild b/dev-lang/go/go-1.11.12.ebuild |
289 |
deleted file mode 100644 |
290 |
index 3797d6e013d..00000000000 |
291 |
--- a/dev-lang/go/go-1.11.12.ebuild |
292 |
+++ /dev/null |
293 |
@@ -1,246 +0,0 @@ |
294 |
-# Copyright 1999-2019 Gentoo Authors |
295 |
-# Distributed under the terms of the GNU General Public License v2 |
296 |
- |
297 |
-EAPI=7 |
298 |
- |
299 |
-export CBUILD=${CBUILD:-${CHOST}} |
300 |
-export CTARGET=${CTARGET:-${CHOST}} |
301 |
- |
302 |
-MY_PV=${PV/_/} |
303 |
- |
304 |
-inherit toolchain-funcs |
305 |
- |
306 |
-BOOTSTRAP_VERSION="bootstrap-1.8" |
307 |
-BOOTSTRAP_DIST="https://dev.gentoo.org/~williamh/dist" |
308 |
-BOOTSTRAP_URI=" |
309 |
- ${BOOTSTRAP_DIST}/go-linux-amd64-${BOOTSTRAP_VERSION}.tbz |
310 |
- ${BOOTSTRAP_DIST}/go-linux-arm-${BOOTSTRAP_VERSION}.tbz |
311 |
- ${BOOTSTRAP_DIST}/go-linux-arm64-${BOOTSTRAP_VERSION}.tbz |
312 |
- ${BOOTSTRAP_DIST}/go-linux-ppc64-${BOOTSTRAP_VERSION}.tbz |
313 |
- ${BOOTSTRAP_DIST}/go-linux-ppc64le-${BOOTSTRAP_VERSION}.tbz |
314 |
- ${BOOTSTRAP_DIST}/go-linux-s390x-${BOOTSTRAP_VERSION}.tbz |
315 |
- ${BOOTSTRAP_DIST}/go-linux-386-${BOOTSTRAP_VERSION}.tbz |
316 |
- ${BOOTSTRAP_DIST}/go-freebsd-amd64-${BOOTSTRAP_VERSION}.tbz |
317 |
- ${BOOTSTRAP_DIST}/go-freebsd-386-${BOOTSTRAP_VERSION}.tbz |
318 |
- ${BOOTSTRAP_DIST}/go-darwin-amd64-${BOOTSTRAP_VERSION}.tbz |
319 |
- ${BOOTSTRAP_DIST}/go-solaris-amd64-${BOOTSTRAP_VERSION}.tbz |
320 |
-" |
321 |
- |
322 |
-case ${PV} in |
323 |
-*9999*) |
324 |
- EGIT_REPO_URI="https://github.com/golang/go.git" |
325 |
- inherit git-r3 |
326 |
- ;; |
327 |
-*) |
328 |
- SRC_URI="https://storage.googleapis.com/golang/go${MY_PV}.src.tar.gz " |
329 |
- S="${WORKDIR}"/go |
330 |
- case ${PV} in |
331 |
- *_beta*|*_rc*) ;; |
332 |
- *) |
333 |
- KEYWORDS="-* ~amd64 ~arm ~arm64 ~ppc64 ~s390 ~x86 ~amd64-fbsd ~x86-fbsd ~amd64-linux ~x64-macos ~x64-solaris" |
334 |
- # The upstream tests fail under portage but pass if the build is |
335 |
- # run according to their documentation [1]. |
336 |
- # I am restricting the tests on released versions until this is |
337 |
- # solved. |
338 |
- # [1] https://golang.org/issues/18442 |
339 |
- RESTRICT="test" |
340 |
- ;; |
341 |
- esac |
342 |
-esac |
343 |
- |
344 |
-# If gccgo or a previously installed version of dev-lang/go is not being |
345 |
-# used to build Go, there is no way to know the architecture or operating system |
346 |
-# of the build machine, so we need to download all of our bootstrap |
347 |
-# archives to allow this ebuild to work under crossdev. |
348 |
-# |
349 |
-# https://bugs.gentoo.org/671394 |
350 |
-SRC_URI+="!gccgo? ( !system-bootstrap? ( ${BOOTSTRAP_URI} ) )" |
351 |
- |
352 |
-DESCRIPTION="A concurrent garbage collected and typesafe programming language" |
353 |
-HOMEPAGE="https://golang.org" |
354 |
- |
355 |
-LICENSE="BSD" |
356 |
-SLOT="0/${PV}" |
357 |
-IUSE="gccgo system-bootstrap" |
358 |
- |
359 |
-BDEPEND="gccgo? ( >=sys-devel/gcc-5[go] )" |
360 |
-RDEPEND="!<dev-go/go-tools-0_pre20150902" |
361 |
- |
362 |
-# These test data objects have writable/executable stacks. |
363 |
-QA_EXECSTACK=" |
364 |
- usr/lib/go/src/debug/elf/testdata/*.obj |
365 |
- usr/lib/go/src/*.gox |
366 |
- " |
367 |
- |
368 |
-# Do not complain about CFLAGS, etc, since Go doesn't use them. |
369 |
-QA_FLAGS_IGNORED='.*' |
370 |
- |
371 |
-REQUIRES_EXCLUDE="/usr/lib/go/src/debug/elf/testdata/*" |
372 |
- |
373 |
-# The tools in /usr/lib/go should not cause the multilib-strict check to fail. |
374 |
-QA_MULTILIB_PATHS="usr/lib/go/pkg/tool/.*/.*" |
375 |
- |
376 |
-# Do not strip this package. Stripping is unsupported upstream and may |
377 |
-# fail. |
378 |
-RESTRICT+=" strip" |
379 |
- |
380 |
-DOCS=( |
381 |
-AUTHORS |
382 |
-CONTRIBUTING.md |
383 |
-CONTRIBUTORS |
384 |
-PATENTS |
385 |
-README.md |
386 |
-) |
387 |
- |
388 |
-go_arch() |
389 |
-{ |
390 |
- # By chance most portage arch names match Go |
391 |
- local portage_arch=$(tc-arch $@) |
392 |
- case "${portage_arch}" in |
393 |
- x86) echo 386;; |
394 |
- x64-*) echo amd64;; |
395 |
- ppc64) [[ $(tc-endian $@) = big ]] && echo ppc64 || echo ppc64le ;; |
396 |
- s390) echo s390x ;; |
397 |
- *) echo "${portage_arch}";; |
398 |
- esac |
399 |
-} |
400 |
- |
401 |
-go_arm() |
402 |
-{ |
403 |
- case "${1:-${CHOST}}" in |
404 |
- armv5*) echo 5;; |
405 |
- armv6*) echo 6;; |
406 |
- armv7*) echo 7;; |
407 |
- *) |
408 |
- die "unknown GOARM for ${1:-${CHOST}}" |
409 |
- ;; |
410 |
- esac |
411 |
-} |
412 |
- |
413 |
-go_os() |
414 |
-{ |
415 |
- case "${1:-${CHOST}}" in |
416 |
- *-linux*) echo linux;; |
417 |
- *-darwin*) echo darwin;; |
418 |
- *-freebsd*) echo freebsd;; |
419 |
- *-netbsd*) echo netbsd;; |
420 |
- *-openbsd*) echo openbsd;; |
421 |
- *-solaris*) echo solaris;; |
422 |
- *-cygwin*|*-interix*|*-winnt*) |
423 |
- echo windows |
424 |
- ;; |
425 |
- *) |
426 |
- die "unknown GOOS for ${1:-${CHOST}}" |
427 |
- ;; |
428 |
- esac |
429 |
-} |
430 |
- |
431 |
-go_tuple() |
432 |
-{ |
433 |
- echo "$(go_os $@)_$(go_arch $@)" |
434 |
-} |
435 |
- |
436 |
-go_cross_compile() |
437 |
-{ |
438 |
- [[ $(go_tuple ${CBUILD}) != $(go_tuple) ]] |
439 |
-} |
440 |
- |
441 |
-pkg_pretend() |
442 |
-{ |
443 |
- # make.bash does not understand cross-compiling a cross-compiler |
444 |
- if [[ $(go_tuple) != $(go_tuple ${CTARGET}) ]]; then |
445 |
- die "CHOST CTARGET pair unsupported: CHOST=${CHOST} CTARGET=${CTARGET}" |
446 |
- fi |
447 |
- [[ ${MERGE_TYPE} != binary ]] && |
448 |
- use system-bootstrap && ! has_version "dev-lang/go" && |
449 |
- die "dev-lang/go must be installed to use the system-bootstrap use flag" |
450 |
-} |
451 |
- |
452 |
-src_unpack() |
453 |
-{ |
454 |
- if [[ ${PV} = 9999 ]]; then |
455 |
- git-r3_src_unpack |
456 |
- else |
457 |
- unpack "go${MY_PV}.src.tar.gz" |
458 |
- fi |
459 |
- use gccgo || use system-bootstrap || |
460 |
- unpack "go-$(go_os ${CBUILD})-$(go_arch ${CBUILD})-${BOOTSTRAP_VERSION}.tbz" |
461 |
-} |
462 |
- |
463 |
-src_compile() |
464 |
-{ |
465 |
- export GOROOT_BOOTSTRAP="${WORKDIR}"/go-$(go_os ${CBUILD})-$(go_arch ${CBUILD})-bootstrap |
466 |
- if use gccgo; then |
467 |
- mkdir -p "${GOROOT_BOOTSTRAP}/bin" || die |
468 |
- local go_binary=$(gcc-config --get-bin-path)/go-$(gcc-major-version) |
469 |
- [[ -x ${go_binary} ]] || go_binary=$( |
470 |
- find "${EPREFIX}"/usr/${CHOST}/gcc-bin/*/go-$(gcc-major-version) | |
471 |
- sort -V | tail -n1) |
472 |
- [[ -x ${go_binary} ]] || |
473 |
- die "go-$(gcc-major-version): command not found" |
474 |
- ln -s "${go_binary}" "${GOROOT_BOOTSTRAP}/bin/go" || die |
475 |
- elif use system-bootstrap; then |
476 |
- export GOROOT_BOOTSTRAP="${EPREFIX}"/usr/lib/go |
477 |
- fi |
478 |
- export GOROOT_FINAL="${EPREFIX}"/usr/lib/go |
479 |
- export GOROOT="$(pwd)" |
480 |
- export GOBIN="${GOROOT}/bin" |
481 |
- |
482 |
- # Go's build script does not use BUILD/HOST/TARGET consistently. :( |
483 |
- export GOHOSTARCH=$(go_arch ${CBUILD}) |
484 |
- export GOHOSTOS=$(go_os ${CBUILD}) |
485 |
- export CC=$(tc-getBUILD_CC) |
486 |
- |
487 |
- export GOARCH=$(go_arch) |
488 |
- export GOOS=$(go_os) |
489 |
- export CC_FOR_TARGET=$(tc-getCC) |
490 |
- export CXX_FOR_TARGET=$(tc-getCXX) |
491 |
- if [[ ${ARCH} == arm ]]; then |
492 |
- export GOARM=$(go_arm) |
493 |
- fi |
494 |
- |
495 |
- cd src |
496 |
- ./make.bash || die "build failed" |
497 |
-} |
498 |
- |
499 |
-src_test() |
500 |
-{ |
501 |
- go_cross_compile && return 0 |
502 |
- |
503 |
- cd src |
504 |
- PATH="${GOBIN}:${PATH}" \ |
505 |
- ./run.bash -no-rebuild || die "tests failed" |
506 |
-} |
507 |
- |
508 |
-src_install() |
509 |
-{ |
510 |
- local bin_path f x |
511 |
- |
512 |
- dodir /usr/lib/go |
513 |
- |
514 |
- # There is a known issue which requires the source tree to be installed [1]. |
515 |
- # Once this is fixed, we can consider using the doc use flag to control |
516 |
- # installing the doc and src directories. |
517 |
- # [1] https://golang.org/issue/2775 |
518 |
- # |
519 |
- # deliberately use cp to retain permissions |
520 |
- cp -R api bin doc lib pkg misc src test "${ED}"/usr/lib/go |
521 |
- if go_cross_compile; then |
522 |
- bin_path="bin/$(go_tuple)" |
523 |
- else |
524 |
- bin_path=bin |
525 |
- fi |
526 |
- for x in ${bin_path}/*; do |
527 |
- f=${x##*/} |
528 |
- dosym ../lib/go/${bin_path}/${f} /usr/bin/${f} |
529 |
- done |
530 |
- einstalldocs |
531 |
- |
532 |
- if [[ ${CHOST} == *-darwin* ]] ; then |
533 |
- # fix install_name for test object (binutils_test) on Darwin, it |
534 |
- # is never used in real circumstances |
535 |
- local libmac64="${EPREFIX}"/usr/lib/go/src/cmd/vendor/github.com/ |
536 |
- libmac64+=google/pprof/internal/binutils/testdata/lib_mac_64 |
537 |
- install_name_tool -id "${libmac64}" "${D}${libmac64}" |
538 |
- fi |
539 |
-} |
540 |
|
541 |
diff --git a/dev-lang/go/go-1.11.13.ebuild b/dev-lang/go/go-1.11.13.ebuild |
542 |
deleted file mode 100644 |
543 |
index b48fe53d64d..00000000000 |
544 |
--- a/dev-lang/go/go-1.11.13.ebuild |
545 |
+++ /dev/null |
546 |
@@ -1,246 +0,0 @@ |
547 |
-# Copyright 1999-2019 Gentoo Authors |
548 |
-# Distributed under the terms of the GNU General Public License v2 |
549 |
- |
550 |
-EAPI=7 |
551 |
- |
552 |
-export CBUILD=${CBUILD:-${CHOST}} |
553 |
-export CTARGET=${CTARGET:-${CHOST}} |
554 |
- |
555 |
-MY_PV=${PV/_/} |
556 |
- |
557 |
-inherit toolchain-funcs |
558 |
- |
559 |
-BOOTSTRAP_VERSION="bootstrap-1.8" |
560 |
-BOOTSTRAP_DIST="https://dev.gentoo.org/~williamh/dist" |
561 |
-BOOTSTRAP_URI=" |
562 |
- ${BOOTSTRAP_DIST}/go-linux-amd64-${BOOTSTRAP_VERSION}.tbz |
563 |
- ${BOOTSTRAP_DIST}/go-linux-arm-${BOOTSTRAP_VERSION}.tbz |
564 |
- ${BOOTSTRAP_DIST}/go-linux-arm64-${BOOTSTRAP_VERSION}.tbz |
565 |
- ${BOOTSTRAP_DIST}/go-linux-ppc64-${BOOTSTRAP_VERSION}.tbz |
566 |
- ${BOOTSTRAP_DIST}/go-linux-ppc64le-${BOOTSTRAP_VERSION}.tbz |
567 |
- ${BOOTSTRAP_DIST}/go-linux-s390x-${BOOTSTRAP_VERSION}.tbz |
568 |
- ${BOOTSTRAP_DIST}/go-linux-386-${BOOTSTRAP_VERSION}.tbz |
569 |
- ${BOOTSTRAP_DIST}/go-freebsd-amd64-${BOOTSTRAP_VERSION}.tbz |
570 |
- ${BOOTSTRAP_DIST}/go-freebsd-386-${BOOTSTRAP_VERSION}.tbz |
571 |
- ${BOOTSTRAP_DIST}/go-darwin-amd64-${BOOTSTRAP_VERSION}.tbz |
572 |
- ${BOOTSTRAP_DIST}/go-solaris-amd64-${BOOTSTRAP_VERSION}.tbz |
573 |
-" |
574 |
- |
575 |
-case ${PV} in |
576 |
-*9999*) |
577 |
- EGIT_REPO_URI="https://github.com/golang/go.git" |
578 |
- inherit git-r3 |
579 |
- ;; |
580 |
-*) |
581 |
- SRC_URI="https://storage.googleapis.com/golang/go${MY_PV}.src.tar.gz " |
582 |
- S="${WORKDIR}"/go |
583 |
- case ${PV} in |
584 |
- *_beta*|*_rc*) ;; |
585 |
- *) |
586 |
- KEYWORDS="-* amd64 arm ~arm64 ~ppc64 ~s390 x86 ~amd64-fbsd ~x86-fbsd ~amd64-linux ~x64-macos ~x64-solaris" |
587 |
- # The upstream tests fail under portage but pass if the build is |
588 |
- # run according to their documentation [1]. |
589 |
- # I am restricting the tests on released versions until this is |
590 |
- # solved. |
591 |
- # [1] https://golang.org/issues/18442 |
592 |
- RESTRICT="test" |
593 |
- ;; |
594 |
- esac |
595 |
-esac |
596 |
- |
597 |
-# If gccgo or a previously installed version of dev-lang/go is not being |
598 |
-# used to build Go, there is no way to know the architecture or operating system |
599 |
-# of the build machine, so we need to download all of our bootstrap |
600 |
-# archives to allow this ebuild to work under crossdev. |
601 |
-# |
602 |
-# https://bugs.gentoo.org/671394 |
603 |
-SRC_URI+="!gccgo? ( !system-bootstrap? ( ${BOOTSTRAP_URI} ) )" |
604 |
- |
605 |
-DESCRIPTION="A concurrent garbage collected and typesafe programming language" |
606 |
-HOMEPAGE="https://golang.org" |
607 |
- |
608 |
-LICENSE="BSD" |
609 |
-SLOT="0/${PV}" |
610 |
-IUSE="gccgo system-bootstrap" |
611 |
- |
612 |
-BDEPEND="gccgo? ( >=sys-devel/gcc-5[go] )" |
613 |
-RDEPEND="!<dev-go/go-tools-0_pre20150902" |
614 |
- |
615 |
-# These test data objects have writable/executable stacks. |
616 |
-QA_EXECSTACK=" |
617 |
- usr/lib/go/src/debug/elf/testdata/*.obj |
618 |
- usr/lib/go/src/*.gox |
619 |
- " |
620 |
- |
621 |
-# Do not complain about CFLAGS, etc, since Go doesn't use them. |
622 |
-QA_FLAGS_IGNORED='.*' |
623 |
- |
624 |
-REQUIRES_EXCLUDE="/usr/lib/go/src/debug/elf/testdata/*" |
625 |
- |
626 |
-# The tools in /usr/lib/go should not cause the multilib-strict check to fail. |
627 |
-QA_MULTILIB_PATHS="usr/lib/go/pkg/tool/.*/.*" |
628 |
- |
629 |
-# Do not strip this package. Stripping is unsupported upstream and may |
630 |
-# fail. |
631 |
-RESTRICT+=" strip" |
632 |
- |
633 |
-DOCS=( |
634 |
-AUTHORS |
635 |
-CONTRIBUTING.md |
636 |
-CONTRIBUTORS |
637 |
-PATENTS |
638 |
-README.md |
639 |
-) |
640 |
- |
641 |
-go_arch() |
642 |
-{ |
643 |
- # By chance most portage arch names match Go |
644 |
- local portage_arch=$(tc-arch $@) |
645 |
- case "${portage_arch}" in |
646 |
- x86) echo 386;; |
647 |
- x64-*) echo amd64;; |
648 |
- ppc64) [[ $(tc-endian $@) = big ]] && echo ppc64 || echo ppc64le ;; |
649 |
- s390) echo s390x ;; |
650 |
- *) echo "${portage_arch}";; |
651 |
- esac |
652 |
-} |
653 |
- |
654 |
-go_arm() |
655 |
-{ |
656 |
- case "${1:-${CHOST}}" in |
657 |
- armv5*) echo 5;; |
658 |
- armv6*) echo 6;; |
659 |
- armv7*) echo 7;; |
660 |
- *) |
661 |
- die "unknown GOARM for ${1:-${CHOST}}" |
662 |
- ;; |
663 |
- esac |
664 |
-} |
665 |
- |
666 |
-go_os() |
667 |
-{ |
668 |
- case "${1:-${CHOST}}" in |
669 |
- *-linux*) echo linux;; |
670 |
- *-darwin*) echo darwin;; |
671 |
- *-freebsd*) echo freebsd;; |
672 |
- *-netbsd*) echo netbsd;; |
673 |
- *-openbsd*) echo openbsd;; |
674 |
- *-solaris*) echo solaris;; |
675 |
- *-cygwin*|*-interix*|*-winnt*) |
676 |
- echo windows |
677 |
- ;; |
678 |
- *) |
679 |
- die "unknown GOOS for ${1:-${CHOST}}" |
680 |
- ;; |
681 |
- esac |
682 |
-} |
683 |
- |
684 |
-go_tuple() |
685 |
-{ |
686 |
- echo "$(go_os $@)_$(go_arch $@)" |
687 |
-} |
688 |
- |
689 |
-go_cross_compile() |
690 |
-{ |
691 |
- [[ $(go_tuple ${CBUILD}) != $(go_tuple) ]] |
692 |
-} |
693 |
- |
694 |
-pkg_pretend() |
695 |
-{ |
696 |
- # make.bash does not understand cross-compiling a cross-compiler |
697 |
- if [[ $(go_tuple) != $(go_tuple ${CTARGET}) ]]; then |
698 |
- die "CHOST CTARGET pair unsupported: CHOST=${CHOST} CTARGET=${CTARGET}" |
699 |
- fi |
700 |
- [[ ${MERGE_TYPE} != binary ]] && |
701 |
- use system-bootstrap && ! has_version "dev-lang/go" && |
702 |
- die "dev-lang/go must be installed to use the system-bootstrap use flag" |
703 |
-} |
704 |
- |
705 |
-src_unpack() |
706 |
-{ |
707 |
- if [[ ${PV} = 9999 ]]; then |
708 |
- git-r3_src_unpack |
709 |
- else |
710 |
- unpack "go${MY_PV}.src.tar.gz" |
711 |
- fi |
712 |
- use gccgo || use system-bootstrap || |
713 |
- unpack "go-$(go_os ${CBUILD})-$(go_arch ${CBUILD})-${BOOTSTRAP_VERSION}.tbz" |
714 |
-} |
715 |
- |
716 |
-src_compile() |
717 |
-{ |
718 |
- export GOROOT_BOOTSTRAP="${WORKDIR}"/go-$(go_os ${CBUILD})-$(go_arch ${CBUILD})-bootstrap |
719 |
- if use gccgo; then |
720 |
- mkdir -p "${GOROOT_BOOTSTRAP}/bin" || die |
721 |
- local go_binary=$(gcc-config --get-bin-path)/go-$(gcc-major-version) |
722 |
- [[ -x ${go_binary} ]] || go_binary=$( |
723 |
- find "${EPREFIX}"/usr/${CHOST}/gcc-bin/*/go-$(gcc-major-version) | |
724 |
- sort -V | tail -n1) |
725 |
- [[ -x ${go_binary} ]] || |
726 |
- die "go-$(gcc-major-version): command not found" |
727 |
- ln -s "${go_binary}" "${GOROOT_BOOTSTRAP}/bin/go" || die |
728 |
- elif use system-bootstrap; then |
729 |
- export GOROOT_BOOTSTRAP="${EPREFIX}"/usr/lib/go |
730 |
- fi |
731 |
- export GOROOT_FINAL="${EPREFIX}"/usr/lib/go |
732 |
- export GOROOT="$(pwd)" |
733 |
- export GOBIN="${GOROOT}/bin" |
734 |
- |
735 |
- # Go's build script does not use BUILD/HOST/TARGET consistently. :( |
736 |
- export GOHOSTARCH=$(go_arch ${CBUILD}) |
737 |
- export GOHOSTOS=$(go_os ${CBUILD}) |
738 |
- export CC=$(tc-getBUILD_CC) |
739 |
- |
740 |
- export GOARCH=$(go_arch) |
741 |
- export GOOS=$(go_os) |
742 |
- export CC_FOR_TARGET=$(tc-getCC) |
743 |
- export CXX_FOR_TARGET=$(tc-getCXX) |
744 |
- if [[ ${ARCH} == arm ]]; then |
745 |
- export GOARM=$(go_arm) |
746 |
- fi |
747 |
- |
748 |
- cd src |
749 |
- ./make.bash || die "build failed" |
750 |
-} |
751 |
- |
752 |
-src_test() |
753 |
-{ |
754 |
- go_cross_compile && return 0 |
755 |
- |
756 |
- cd src |
757 |
- PATH="${GOBIN}:${PATH}" \ |
758 |
- ./run.bash -no-rebuild || die "tests failed" |
759 |
-} |
760 |
- |
761 |
-src_install() |
762 |
-{ |
763 |
- local bin_path f x |
764 |
- |
765 |
- dodir /usr/lib/go |
766 |
- |
767 |
- # There is a known issue which requires the source tree to be installed [1]. |
768 |
- # Once this is fixed, we can consider using the doc use flag to control |
769 |
- # installing the doc and src directories. |
770 |
- # [1] https://golang.org/issue/2775 |
771 |
- # |
772 |
- # deliberately use cp to retain permissions |
773 |
- cp -R api bin doc lib pkg misc src test "${ED}"/usr/lib/go |
774 |
- if go_cross_compile; then |
775 |
- bin_path="bin/$(go_tuple)" |
776 |
- else |
777 |
- bin_path=bin |
778 |
- fi |
779 |
- for x in ${bin_path}/*; do |
780 |
- f=${x##*/} |
781 |
- dosym ../lib/go/${bin_path}/${f} /usr/bin/${f} |
782 |
- done |
783 |
- einstalldocs |
784 |
- |
785 |
- if [[ ${CHOST} == *-darwin* ]] ; then |
786 |
- # fix install_name for test object (binutils_test) on Darwin, it |
787 |
- # is never used in real circumstances |
788 |
- local libmac64="${EPREFIX}"/usr/lib/go/src/cmd/vendor/github.com/ |
789 |
- libmac64+=google/pprof/internal/binutils/testdata/lib_mac_64 |
790 |
- install_name_tool -id "${libmac64}" "${D}${libmac64}" |
791 |
- fi |
792 |
-} |