1 |
commit: 29ace82844506914a4bc6af204e140ccdc730800 |
2 |
Author: Gilles Dartiguelongue <eva <AT> gentoo <DOT> org> |
3 |
AuthorDate: Sun Oct 30 11:36:40 2016 +0000 |
4 |
Commit: Gilles Dartiguelongue <eva <AT> gentoo <DOT> org> |
5 |
CommitDate: Sun Oct 30 11:36:40 2016 +0000 |
6 |
URL: https://gitweb.gentoo.org/proj/gnome.git/commit/?id=29ace828 |
7 |
|
8 |
eclass/gnome2-live: add EAPI 6 support |
9 |
|
10 |
eclass/gnome2-live.eclass | 36 ++++++++++++++++++++++++------------ |
11 |
1 file changed, 24 insertions(+), 12 deletions(-) |
12 |
|
13 |
diff --git a/eclass/gnome2-live.eclass b/eclass/gnome2-live.eclass |
14 |
index 0e725d0..8bcc4ea 100644 |
15 |
--- a/eclass/gnome2-live.eclass |
16 |
+++ b/eclass/gnome2-live.eclass |
17 |
@@ -21,6 +21,9 @@ case "${EAPI:-0}" in |
18 |
4|5) |
19 |
EXPORT_FUNCTIONS src_unpack src_prepare pkg_postinst |
20 |
;; |
21 |
+ 6) |
22 |
+ EXPORT_FUNCTIONS src_prepare pkg_postinst |
23 |
+ ;; |
24 |
*) |
25 |
die "Unknown EAPI, Bug eclass maintainers." ;; |
26 |
esac |
27 |
@@ -75,11 +78,15 @@ gnome2-live_get_var() { |
28 |
# Calls git-2_src_unpack, and unpacks ${A} if required. |
29 |
# Also calls gnome2-live_src_prepare for older EAPI. |
30 |
gnome2-live_src_unpack() { |
31 |
- if test -n "${A}"; then |
32 |
- unpack ${A} |
33 |
+ if has ${EAPI:-0} 4 5 ; then |
34 |
+ if test -n "${A}"; then |
35 |
+ unpack ${A} |
36 |
+ fi |
37 |
+ git-r3_src_unpack |
38 |
+ gnome2-live_src_prepare |
39 |
+ else |
40 |
+ die "gnome2-live_src_unpack is banned starting with EAPI=6" |
41 |
fi |
42 |
- git-r3_src_unpack |
43 |
- gnome2-live_src_prepare |
44 |
} |
45 |
|
46 |
# @FUNCTION: gnome2-live_src_prepare |
47 |
@@ -88,11 +95,13 @@ gnome2-live_src_unpack() { |
48 |
# Creates blank ChangeLog and necessary macro dirs. Runs various autotools |
49 |
# programs if required, and finally runs eautoreconf. |
50 |
gnome2-live_src_prepare() { |
51 |
- for i in ${PATCHES}; do |
52 |
- epatch "${i}" |
53 |
- done |
54 |
+ if has ${EAPI:-0} 4 5 ; then |
55 |
+ for i in ${PATCHES}; do |
56 |
+ epatch "${i}" |
57 |
+ done |
58 |
|
59 |
- epatch_user |
60 |
+ epatch_user |
61 |
+ fi |
62 |
|
63 |
# If ChangeLog doesn't exist, maybe it's autogenerated |
64 |
# Avoid a `dodoc` failure by adding an empty ChangeLog |
65 |
@@ -100,18 +109,21 @@ gnome2-live_src_prepare() { |
66 |
echo > ChangeLog |
67 |
fi |
68 |
|
69 |
- # eautoreconf is smart enough to run all necessary commands |
70 |
- eautoreconf |
71 |
- |
72 |
### Keep this in-sync with gnome2.eclass! |
73 |
|
74 |
xdg_src_prepare |
75 |
|
76 |
+ # eautoreconf is smart enough to run all necessary commands |
77 |
+ eautoreconf |
78 |
+ |
79 |
# Prevent assorted access violations and test failures |
80 |
gnome2_environment_reset |
81 |
|
82 |
# Prevent scrollkeeper access violations |
83 |
- gnome2_omf_fix |
84 |
+ # We stop to run it from EAPI=6 as scrollkeeper helpers from |
85 |
+ # rarian are not running anything and, then, access violations |
86 |
+ # shouldn't occur. |
87 |
+ has ${EAPI:-0} 4 5 && gnome2_omf_fix |
88 |
|
89 |
# Run libtoolize |
90 |
# https://bugzilla.gnome.org/show_bug.cgi?id=655517 |