toolchain.eclass: advertise fortran support for >=gcc-4.2+
authorSergei Trofimovich <slyfox@gentoo.org>
Sun, 10 Nov 2019 18:21:50 +0000 (18:21 +0000)
committerSergei Trofimovich <slyfox@gentoo.org>
Sun, 10 Nov 2019 18:27:10 +0000 (18:27 +0000)
Signed-off-by: Sergei Trofimovich <slyfox@gentoo.org>
eclass/toolchain.eclass

index 99643eafdd0fe6f07be3c2ff0276308714ef0297..a3081c38bac1683744a0490e2c009e8bd944d02a 100644 (file)
@@ -147,11 +147,13 @@ tc_has_feature() {
 }
 
 if [[ ${PN} != "kgcc64" && ${PN} != gcc-* ]] ; then
-       IUSE+=" altivec debug +cxx +fortran +nptl" TC_FEATURES+=(fortran nptl)
+       IUSE+=" altivec debug +cxx +nptl" TC_FEATURES+=(nptl)
        [[ -n ${PIE_VER} ]] && IUSE+=" nopie"
        [[ -n ${HTB_VER} ]] && IUSE+=" boundschecking"
        [[ -n ${D_VER}   ]] && IUSE+=" d"
        [[ -n ${SPECS_VER} ]] && IUSE+=" nossp"
+       # fortran support appeared in 4.1, but 4.1 needs outdated mpfr
+       tc_version_is_at_least 4.2 && IUSE+=" +fortran" TC_FEATURES+=(fortran)
        tc_version_is_at_least 3 && IUSE+=" doc hardened multilib objc"
        tc_version_is_between 3 7 && IUSE+=" awt gcj" TC_FEATURES+=(gcj)
        tc_version_is_at_least 3.3 && IUSE+=" pgo"