1 |
Nothing exciting there, basically s/epatch/eapply/ and don't inherit |
2 |
eutils in EAPI 6. |
3 |
|
4 |
I'll commit this tomorrow unless someone will point out a bug. |
5 |
|
6 |
Ulrich |
7 |
|
8 |
|
9 |
From 37929a17e2e3977b6f811915e6ef23f557c0f241 Mon Sep 17 00:00:00 2001 |
10 |
From: =?UTF-8?q?Ulrich=20M=C3=BCller?= <ulm@g.o> |
11 |
Date: Sat, 19 Dec 2015 13:08:36 +0100 |
12 |
Subject: [PATCH] elisp.eclass: Support EAPI 6. |
13 |
|
14 |
--- |
15 |
eclass/elisp.eclass | 35 +++++++++++++++++++++++++---------- |
16 |
1 file changed, 25 insertions(+), 10 deletions(-) |
17 |
|
18 |
diff --git a/eclass/elisp.eclass b/eclass/elisp.eclass |
19 |
index 1178880..93a7d4b 100644 |
20 |
--- a/eclass/elisp.eclass |
21 |
+++ b/eclass/elisp.eclass |
22 |
@@ -65,13 +65,21 @@ |
23 |
# DOCS="blah.txt ChangeLog" is automatically used to install the given |
24 |
# files by dodoc in src_install(). |
25 |
|
26 |
-inherit elisp-common eutils |
27 |
+inherit elisp-common |
28 |
|
29 |
case ${EAPI:-0} in |
30 |
- 0|1) EXPORT_FUNCTIONS src_{unpack,compile,install} \ |
31 |
- pkg_{setup,postinst,postrm} ;; |
32 |
- *) EXPORT_FUNCTIONS src_{unpack,prepare,configure,compile,install} \ |
33 |
- pkg_{setup,postinst,postrm} ;; |
34 |
+ 0|1) |
35 |
+ inherit eutils |
36 |
+ EXPORT_FUNCTIONS src_{unpack,compile,install} \ |
37 |
+ pkg_{setup,postinst,postrm} ;; |
38 |
+ 2|3|4|5) |
39 |
+ inherit eutils |
40 |
+ EXPORT_FUNCTIONS src_{unpack,prepare,configure,compile,install} \ |
41 |
+ pkg_{setup,postinst,postrm} ;; |
42 |
+ 6) |
43 |
+ EXPORT_FUNCTIONS src_{unpack,prepare,configure,compile,install} \ |
44 |
+ pkg_{setup,postinst,postrm} ;; |
45 |
+ *) die "${ECLASS}: EAPI ${EAPI} not supported" ;; |
46 |
esac |
47 |
|
48 |
DEPEND=">=virtual/emacs-${NEED_EMACS:-23}" |
49 |
@@ -117,21 +125,28 @@ elisp_src_unpack() { |
50 |
# for in the current working dir, WORKDIR, and FILESDIR. |
51 |
|
52 |
elisp_src_prepare() { |
53 |
- local patch |
54 |
+ local patch file |
55 |
for patch in ${ELISP_PATCHES}; do |
56 |
if [[ -f ${patch} ]]; then |
57 |
- epatch "${patch}" |
58 |
+ file="${patch}" |
59 |
elif [[ -f ${WORKDIR}/${patch} ]]; then |
60 |
- epatch "${WORKDIR}/${patch}" |
61 |
+ file="${WORKDIR}/${patch}" |
62 |
elif [[ -f ${FILESDIR}/${patch} ]]; then |
63 |
- epatch "${FILESDIR}/${patch}" |
64 |
+ file="${FILESDIR}/${patch}" |
65 |
else |
66 |
die "Cannot find ${patch}" |
67 |
fi |
68 |
+ case ${EAPI:-0} in |
69 |
+ 0|1|2|3|4|5) epatch "${file}" ;; |
70 |
+ 6) eapply "${file}" ;; |
71 |
+ esac |
72 |
done |
73 |
|
74 |
# apply any user patches |
75 |
- epatch_user |
76 |
+ case ${EAPI:-0} in |
77 |
+ 0|1|2|3|4|5) epatch_user ;; |
78 |
+ 6) eapply_user ;; |
79 |
+ esac |
80 |
|
81 |
if [[ -n ${ELISP_REMOVE} ]]; then |
82 |
rm ${ELISP_REMOVE} || die |
83 |
-- |
84 |
2.6.4 |