[gnome-commander/gcmd-1-10] Check for gcc-8 in gentoo ebuild via toolchain-funcs method



commit 1eebc3c43bc6516171c6bea1fd625d45637b506a
Author: Uwe Scholz <u scholz83 gmx de>
Date:   Mon Jul 8 22:07:29 2019 +0200

    Check for gcc-8 in gentoo ebuild via toolchain-funcs method

 data/gnome-commander.ebuild.in | 9 ++++++++-
 1 file changed, 8 insertions(+), 1 deletion(-)
---
diff --git a/data/gnome-commander.ebuild.in b/data/gnome-commander.ebuild.in
index dc4513b5..8be3e7aa 100644
--- a/data/gnome-commander.ebuild.in
+++ b/data/gnome-commander.ebuild.in
@@ -5,7 +5,7 @@ EAPI=6
 
 GNOME2_LA_PUNT="yes"
 
-inherit gnome2
+inherit gnome2 toolchain-funcs
 
 DESCRIPTION="A graphical, full featured, twin-panel file manager"
 HOMEPAGE="https://gcmd.github.io/";
@@ -51,6 +51,13 @@ src_configure() {
                $(use_with unique)
 }
 
+pkg_pretend() {
+       if tc-is-gcc && [[ $(gcc-major-version) -lt 8 ]]; then
+               eerror "Compilation with gcc older than version 8 is not supported"
+               die "GCC too old, please use gcc-8 or above"
+       fi
+}
+
 pkg_postinst() {
        gnome2_pkg_postinst
        has_version dev-util/meld || elog "You need dev-util/meld to synchronize files and directories."


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]