1 |
Fixed naming the proper default sub-phase and declaring 'edefault' |
2 |
in python_prepare_all(). |
3 |
--- |
4 |
gx86/eclass/distutils-r1.eclass | 22 ++++++++++++++++++++++ |
5 |
1 file changed, 22 insertions(+) |
6 |
|
7 |
diff --git a/gx86/eclass/distutils-r1.eclass b/gx86/eclass/distutils-r1.eclass |
8 |
index 47b5b97..e5c2a3a 100644 |
9 |
--- a/gx86/eclass/distutils-r1.eclass |
10 |
+++ b/gx86/eclass/distutils-r1.eclass |
11 |
@@ -206,6 +206,20 @@ fi |
12 |
# } |
13 |
# @CODE |
14 |
|
15 |
+# @FUNCTION: edefault |
16 |
+# @USAGE: [<args>...] |
17 |
+# @DESCRIPTION: |
18 |
+# Runs the default distutils-r1 sub-phase implementation for the current |
19 |
+# sub-phase. Available only in distutils-r1 sub-phases. |
20 |
+# |
21 |
+# Example: |
22 |
+# @CODE |
23 |
+# python_install_all() { |
24 |
+# use doc && local HTML_DOCS=( doc/html/. ) |
25 |
+# edefault # == distutils-r1_python_install_all |
26 |
+# } |
27 |
+# @CODE |
28 |
+ |
29 |
# @FUNCTION: esetup.py |
30 |
# @USAGE: [<args>...] |
31 |
# @DESCRIPTION: |
32 |
@@ -515,8 +529,12 @@ distutils-r1_run_phase() { |
33 |
|
34 |
mkdir -p "${TMPDIR}" || die |
35 |
|
36 |
+ eval "edefault() { distutils-r1_${1}; }" |
37 |
+ |
38 |
"${@}" |
39 |
|
40 |
+ unset -f edefault |
41 |
+ |
42 |
if [[ ${DISTUTILS_IN_SOURCE_BUILD} && ! ${DISTUTILS_SINGLE_IMPL} ]] |
43 |
then |
44 |
popd >/dev/null || die |
45 |
@@ -579,7 +597,11 @@ distutils-r1_src_prepare() { |
46 |
|
47 |
# common preparations |
48 |
if declare -f python_prepare_all >/dev/null; then |
49 |
+ eval "edefault() { distutils-r1_python_prepare_all; }" |
50 |
+ |
51 |
python_prepare_all |
52 |
+ |
53 |
+ unset -f edefault |
54 |
else |
55 |
distutils-r1_python_prepare_all |
56 |
fi |
57 |
-- |
58 |
1.8.2.1 |