diff options
author | Marek Szuba <marecki@gentoo.org> | 2021-07-16 12:53:57 +0100 |
---|---|---|
committer | Marek Szuba <marecki@gentoo.org> | 2021-07-20 17:36:33 +0100 |
commit | b40ddb4f450aa66f3021f31991dafc1fd1e97733 (patch) | |
tree | 449f8b76a8c650966eb89f17f38ccafba92212d9 /eclass/fortran-2.eclass | |
parent | app-backup/borgmatic: keyword 1.5.15 for ~riscv (diff) | |
download | gentoo-b40ddb4f450aa66f3021f31991dafc1fd1e97733.tar.gz gentoo-b40ddb4f450aa66f3021f31991dafc1fd1e97733.tar.bz2 gentoo-b40ddb4f450aa66f3021f31991dafc1fd1e97733.zip |
fortran-2.eclass: use BDEPEND on EAPI 7+
For FORTRAN_NEEDED=test we need both the compiler and the test binaries
to run on the build host only, hence new EAPIs only set BDEPEND here;
For other modes (other than "no", of course), we need a Fortran compiler
running on the build host as well as the runtime libraries built for the
target arch, necessitating the use of both DEPEND and BDEPEND on newer
EAPIs.
Closes: https://bugs.gentoo.org/802153
Signed-off-by: Marek Szuba <marecki@gentoo.org>
Diffstat (limited to 'eclass/fortran-2.eclass')
-rw-r--r-- | eclass/fortran-2.eclass | 12 |
1 files changed, 11 insertions, 1 deletions
diff --git a/eclass/fortran-2.eclass b/eclass/fortran-2.eclass index 9d0c71703e49..2409cfcda5be 100644 --- a/eclass/fortran-2.eclass +++ b/eclass/fortran-2.eclass @@ -69,6 +69,9 @@ if [[ ! ${_FORTRAN_2_CLASS} ]]; then for _f_use in ${FORTRAN_NEEDED}; do case ${_f_use} in always) + if [[ ${EAPI} != [56] ]]; then + BDEPEND+=" virtual/fortran" + fi DEPEND+=" virtual/fortran" RDEPEND+=" virtual/fortran" break @@ -77,9 +80,16 @@ for _f_use in ${FORTRAN_NEEDED}; do break ;; test) - DEPEND+=" ${_f_use}? ( virtual/fortran )" + if [[ ${EAPI} != [56] ]]; then + BDEPEND+=" ${_f_use}? ( virtual/fortran )" + else + DEPEND+=" ${_f_use}? ( virtual/fortran )" + fi ;; *) + if [[ ${EAPI} != [56] ]]; then + BDEPEND+=" ${_f_use}? ( virtual/fortran )" + fi DEPEND+=" ${_f_use}? ( virtual/fortran )" RDEPEND+=" ${_f_use}? ( virtual/fortran )" ;; |