Gentoo Archives: gentoo-commits

From: Sergei Trofimovich <slyfox@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: sys-devel/gcc-config/
Date: Sun, 12 Jan 2020 16:12:59
Message-Id: 1578845571.905d857799082dbd18c1a5e5cfce03da074d2178.slyfox@gentoo
1 commit: 905d857799082dbd18c1a5e5cfce03da074d2178
2 Author: Sergei Trofimovich <slyfox <AT> gentoo <DOT> org>
3 AuthorDate: Sun Jan 12 16:10:43 2020 +0000
4 Commit: Sergei Trofimovich <slyfox <AT> gentoo <DOT> org>
5 CommitDate: Sun Jan 12 16:12:51 2020 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=905d8577
7
8 sys-devel/gcc-config: bump up to 2.2
9
10 New version to support gcc-10.
11
12 Package-Manager: Portage-2.3.84, Repoman-2.3.20
13 Signed-off-by: Sergei Trofimovich <slyfox <AT> gentoo.org>
14
15 sys-devel/gcc-config/Manifest | 1 +
16 sys-devel/gcc-config/gcc-config-2.2.ebuild | 54 ++++++++++++++++++++++++++++++
17 2 files changed, 55 insertions(+)
18
19 diff --git a/sys-devel/gcc-config/Manifest b/sys-devel/gcc-config/Manifest
20 index a185bd11b6c..49cbdf9d04f 100644
21 --- a/sys-devel/gcc-config/Manifest
22 +++ b/sys-devel/gcc-config/Manifest
23 @@ -1 +1,2 @@
24 DIST gcc-config-2.1.tar.xz 15520 BLAKE2B 0e37762877116d90265a31cf6d9bc99da9b358afc26c0f7cb6fdbbb44dce23ebf59a1d5c2e481d456c03fbcc383efb7a56559af0bbd1f2bd78f407a853c88369 SHA512 0b19cb758a1e8c5e2e1f7901799fa1eb598d9d5c8d89ceace2e294ec569bfa90978bef72f52b9c2a3455f2ffd21be0899fb3e23b5fbdf62b70e978c153961272
25 +DIST gcc-config-2.2.tar.xz 15956 BLAKE2B c83c1e2584c42d5e6317e044fc6681f5006d9158ecb8d7127383a773e0b51fc2388aab9462088c087a877d77f8ee0631eb00b48b4ef13125af2bbb3871ea2582 SHA512 501d870488ebbeab2e704cab046b6432379c0dcf430fa24737fc97d9a0aa635e25fd4f7c0b7983f349ffd4c378b1971e4c8c82dc524b4916415985a6e0e7480b
26
27 diff --git a/sys-devel/gcc-config/gcc-config-2.2.ebuild b/sys-devel/gcc-config/gcc-config-2.2.ebuild
28 new file mode 100644
29 index 00000000000..14719662eb8
30 --- /dev/null
31 +++ b/sys-devel/gcc-config/gcc-config-2.2.ebuild
32 @@ -0,0 +1,54 @@
33 +# Copyright 1999-2020 Gentoo Authors
34 +# Distributed under the terms of the GNU General Public License v2
35 +
36 +EAPI=7
37 +
38 +inherit toolchain-funcs
39 +
40 +if [[ ${PV} == 9999 ]]; then
41 + EGIT_REPO_URI="https://anongit.gentoo.org/git/proj/gcc-config.git"
42 + inherit git-r3
43 +else
44 + SRC_URI="mirror://gentoo/${P}.tar.xz
45 + https://dev.gentoo.org/~slyfox/distfiles/${P}.tar.xz"
46 + KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~riscv ~s390 ~sh ~sparc ~x86"
47 +fi
48 +
49 +DESCRIPTION="Utility to manage compilers"
50 +HOMEPAGE="https://gitweb.gentoo.org/proj/gcc-config.git/"
51 +LICENSE="GPL-2"
52 +SLOT="0"
53 +IUSE=""
54 +
55 +RDEPEND=">=sys-apps/gentoo-functions-0.10"
56 +
57 +src_compile() {
58 + emake CC="$(tc-getCC)" \
59 + PV="${PV}" \
60 + SUBLIBDIR="$(get_libdir)"
61 +}
62 +
63 +src_install() {
64 + emake \
65 + DESTDIR="${D}" \
66 + PV="${PV}" \
67 + SUBLIBDIR="$(get_libdir)" \
68 + install
69 +}
70 +
71 +pkg_postinst() {
72 + # Scrub eselect-compiler remains
73 + rm -f "${ROOT}"/etc/env.d/05compiler &
74 +
75 + # We not longer use the /usr/include/g++-v3 hacks, as
76 + # it is not needed ...
77 + rm -f "${ROOT}"/usr/include/g++{,-v3} &
78 +
79 + # Do we have a valid multi ver setup ?
80 + local x
81 + for x in $(gcc-config -C -l 2>/dev/null | awk '$NF == "*" { print $2 }') ; do
82 + gcc-config ${x}
83 + done
84 +
85 + wait
86 +}