1 |
So here are the last changes. Everything is in pkg_setup now, because of |
2 |
the dependency problem found by Ciaran. |
3 |
|
4 |
|
5 |
|
6 |
|
7 |
eclass/fortran-2.eclass | 28 ++++++---------------------- |
8 |
1 files changed, 6 insertions(+), 22 deletions(-) |
9 |
|
10 |
diff --git a/eclass/fortran-2.eclass b/eclass/fortran-2.eclass |
11 |
index 600d107..3f35197 100644 |
12 |
--- a/eclass/fortran-2.eclass |
13 |
+++ b/eclass/fortran-2.eclass |
14 |
@@ -16,7 +16,7 @@ |
15 |
# and exports the variables FC and F77. |
16 |
# Optionally, it checks for extended capabilities based on |
17 |
# the variable options selected in the ebuild |
18 |
-# The only phase functions exported are pkg_pretend and pkg_setup. |
19 |
+# The only phase function exported is fortran-2_pkg_setup. |
20 |
|
21 |
# @ECLASS-VARIABLE: FORTRAN_NEED_OPENMP |
22 |
# @DESCRIPTION: |
23 |
@@ -122,10 +122,10 @@ _die_msg() { |
24 |
die "Currently no working fortran compiler is available" |
25 |
} |
26 |
|
27 |
-# @FUNCTION: fortran-2_pkg_pretend |
28 |
+# @FUNCTION: fortran-2_pkg_setup |
29 |
# @DESCRIPTION: |
30 |
# Setup functionallity, checks for a valid fortran compiler and |
31 |
optionally for its openmp support. |
32 |
-fortran-2_pkg_pretend() { |
33 |
+fortran-2_pkg_setup() { |
34 |
local dialect |
35 |
|
36 |
: ${F77:=$(tc-getFC)} |
37 |
@@ -145,27 +145,11 @@ fortran-2_pkg_pretend() { |
38 |
_fortran-has-openmp || \ |
39 |
die "Please install current gcc with USE=openmp or set the FC |
40 |
variable to a compiler that supports OpenMP" |
41 |
fi |
42 |
-} |
43 |
- |
44 |
-# @FUNCTION: fortran-2_pkg_setup |
45 |
-# @DESCRIPTION: |
46 |
-# In EAPI < 4 it calls the compiler check. This behavior is deprecated |
47 |
-# and will be removed at 01-Okt-2011. Please migrate to EAPI=4. |
48 |
-# |
49 |
-# Exports the FC and F77 variable according to the compiler checks. |
50 |
-fortran-2_pkg_setup() { |
51 |
- if has ${EAPI:-0} 0 1 2 3; then |
52 |
- ewarn "The support for EAPI=${EAPI} by the fortran-2.eclass" |
53 |
- ewarn "will be end at 01-Okt-2011" |
54 |
- ewarn "Please migrate your package to EAPI=4" |
55 |
- fortran-2_pkg_pretend |
56 |
- fi |
57 |
- [[ -n ${F77} ]] || export F77=$(tc-getFC) |
58 |
- [[ -n ${FC} ]] || export FC=$(tc-getFC) |
59 |
+ tc-export F77 |
60 |
+ tc-export FC |
61 |
} |
62 |
|
63 |
case ${EAPI:-0} in |
64 |
- 1|2|3) EXPORT_FUNCTIONS pkg_setup ;; |
65 |
- 4) EXPORT_FUNCTIONS pkg_pretend pkg_setup ;; |
66 |
+ 1|2|3|4) EXPORT_FUNCTIONS pkg_setup ;; |
67 |
*) die "EAPI=${EAPI} is not supported" ;; |
68 |
esac |