commit:     88d3cf89b62f5b2ef7813aaf21a49ba94102cd44
Author:     Sergei Trofimovich <slyfox <AT> gentoo <DOT> org>
AuthorDate: Sun Feb 28 09:46:48 2021 +0000
Commit:     Sergei Trofimovich <slyfox <AT> gentoo <DOT> org>
CommitDate: Sun Feb 28 09:50:11 2021 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=88d3cf89

sys-devel/gcc-config: bump up to 2.4

One user visible change:
- gcc-config: add support for special 'latest' version for profile switch

Bug: https://bugs.gentoo.org/765664
Package-Manager: Portage-3.0.16, Repoman-3.0.2
Signed-off-by: Sergei Trofimovich <slyfox <AT> gentoo.org>

 sys-devel/gcc-config/Manifest              |  1 +
 sys-devel/gcc-config/gcc-config-2.4.ebuild | 53 ++++++++++++++++++++++++++++++
 2 files changed, 54 insertions(+)

diff --git a/sys-devel/gcc-config/Manifest b/sys-devel/gcc-config/Manifest
index 38fb58fecf8..0274ff30b10 100644
--- a/sys-devel/gcc-config/Manifest
+++ b/sys-devel/gcc-config/Manifest
@@ -1,2 +1,3 @@
 DIST gcc-config-2.3.2.tar.xz 17444 BLAKE2B 
c66fd121770dddcb27033be228de691f766f1acd9ada9580ae96dc12f6fbd0cd823e6656dc9b0515d498305b10d72f9cd87cf69388791971e9eac1a20e3f97c9
 SHA512 
31327d9abd26fdadaaf25a63568fd860ae25030b4a99dcbf0424f2d8fb14e61f041e681eea90c781a3f4e5401e3a7ba3299b1260ceb6e51bda5bef24f65dcacc
 DIST gcc-config-2.3.3.tar.xz 17452 BLAKE2B 
fb77e2a2ea3d57142e6784d985364f3c0c82c149af10ac0a6490b3f4acceb3cd86e9d25168a60c532dd2bfce300a12a13cfc0eb290bf8c9457e43b9acf247328
 SHA512 
110af5a15e34c41f8f0568f20215bd4b0db2ffd2e65a4c3e7c3a6695c0de574e85478582cd65b627591ee754cd7f28c01ab8f3c3a101ed00c2b42fedab58a08a
+DIST gcc-config-2.4.tar.xz 17552 BLAKE2B 
631645a5cc9f3e7ab0ff089960ee3d0b2ecea29aa96f839a03a86985db512bf0d182b67a7b1bb73b95808c04523f32d6b8c122cdfbe8dbf94e7d319a1e49a23c
 SHA512 
852b4aefaccfae1d91c551e226ac28110fa23f9668075c190a5fb9129c86d2f3e4994e96b7a5e8a2801883c5a5b16d9fbf3e9066e6b6a423055fdefa490793c7

diff --git a/sys-devel/gcc-config/gcc-config-2.4.ebuild 
b/sys-devel/gcc-config/gcc-config-2.4.ebuild
new file mode 100644
index 00000000000..33b842037c4
--- /dev/null
+++ b/sys-devel/gcc-config/gcc-config-2.4.ebuild
@@ -0,0 +1,53 @@
+# Copyright 1999-2021 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=7
+
+inherit toolchain-funcs
+
+if [[ ${PV} == 9999 ]]; then
+       EGIT_REPO_URI="https://anongit.gentoo.org/git/proj/gcc-config.git";
+       inherit git-r3
+else
+       SRC_URI="https://dev.gentoo.org/~slyfox/distfiles/${P}.tar.xz";
+       KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 
~riscv ~s390 ~sparc ~x86"
+fi
+
+DESCRIPTION="Utility to manage compilers"
+HOMEPAGE="https://gitweb.gentoo.org/proj/gcc-config.git/";
+LICENSE="GPL-2"
+SLOT="0"
+IUSE="+cc-wrappers +native-symlinks"
+
+RDEPEND=">=sys-apps/gentoo-functions-0.10"
+
+_emake() {
+       emake \
+               PV="${PVR}" \
+               SUBLIBDIR="$(get_libdir)" \
+               USE_CC_WRAPPERS="$(usex cc-wrappers)" \
+               USE_NATIVE_LINKS="$(usex native-symlinks)" \
+               TOOLCHAIN_PREFIX="${CHOST}-" \
+               "$@"
+}
+
+src_compile() {
+       _emake
+}
+
+src_install() {
+       _emake DESTDIR="${D}" install
+}
+
+pkg_postinst() {
+       # Do we have a valid multi ver setup ?
+       local x
+       for x in $(gcc-config -C -l 2>/dev/null | awk '$NF == "*" { print $2 
}') ; do
+               gcc-config ${x}
+       done
+
+       # USE flag change can add or delete files in /usr/bin worth recaching
+       if [[ ! ${ROOT} && -f 
${EPREFIX}/usr/share/eselect/modules/compiler-shadow.eselect ]] ; then
+               eselect compiler-shadow update all
+       fi
+}

Reply via email to