On 6/13/11 11:06 AM, justin wrote: > # @FUNCTION: fortran-2_pkg_setup > # @DESCRIPTION: > # Setup functionallity, checks for a valid fortran compiler and optionally > for its openmp support. > fortran-2_pkg_setup() { > _have-valid-fortran || \ > die "Please emerge the current gcc with USE=fortran or export > FC defining a working fortran compiler" > export FC=$(tc-getFC) > export F77=$(tc-getFC) > export F90=$(tc-getFC) > export F95=$(tc-getFC) > if [[ ${FC_NEED_OPENMP} == 1 ]]; then > _fortran-has-openmp || \ > die "Please emerge current gcc with USE=openmp or export FC > with compiler that supports OpenMP" > fi > } > > EXPORT_FUNCTIONS pkg_setup
I wonder if it's possible to take advantage of EAPI4's pkg_pretend, and fall back to pkg_setup for older EAPIs. pkg_pretend makes it possible to fix the setup before running emerge, instead of things breaking in the middle. It's just a suggestion.
signature.asc
Description: OpenPGP digital signature