1 |
ulm 11/09/26 12:31:16 |
2 |
|
3 |
Modified: metadata.xml ChangeLog |
4 |
emacs-vcs-24.0.9999-r1.ebuild |
5 |
emacs-vcs-23.3.9999.ebuild |
6 |
Added: emacs-vcs-24.0.90.ebuild |
7 |
Log: |
8 |
First pretest for Emacs 24.1. Merge changes from Emacs overlay: Link against libXaw with USE=athena. Change [ ] to [[ ]] throughout. Remove outdated warning. |
9 |
|
10 |
(Portage version: 2.1.10.19/cvs/Linux x86_64) |
11 |
|
12 |
Revision Changes Path |
13 |
1.8 app-editors/emacs-vcs/metadata.xml |
14 |
|
15 |
file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/app-editors/emacs-vcs/metadata.xml?rev=1.8&view=markup |
16 |
plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/app-editors/emacs-vcs/metadata.xml?rev=1.8&content-type=text/plain |
17 |
diff : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/app-editors/emacs-vcs/metadata.xml?r1=1.7&r2=1.8 |
18 |
|
19 |
Index: metadata.xml |
20 |
=================================================================== |
21 |
RCS file: /var/cvsroot/gentoo-x86/app-editors/emacs-vcs/metadata.xml,v |
22 |
retrieving revision 1.7 |
23 |
retrieving revision 1.8 |
24 |
diff -u -r1.7 -r1.8 |
25 |
--- metadata.xml 19 Jul 2011 07:28:32 -0000 1.7 |
26 |
+++ metadata.xml 26 Sep 2011 12:31:15 -0000 1.8 |
27 |
@@ -20,6 +20,8 @@ |
28 |
available separately. |
29 |
</longdescription> |
30 |
<use> |
31 |
+ <flag name='athena'>Enable the MIT Athena widget set |
32 |
+ (<pkg>x11-libs/libXaw</pkg>)</flag> |
33 |
<flag name='gconf'>Use <pkg>gnome-base/gconf</pkg> to read the system |
34 |
font name</flag> |
35 |
<flag name='gsettings'>Use gsettings (<pkg>dev-libs/glib</pkg>) to read the |
36 |
|
37 |
|
38 |
|
39 |
1.63 app-editors/emacs-vcs/ChangeLog |
40 |
|
41 |
file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/app-editors/emacs-vcs/ChangeLog?rev=1.63&view=markup |
42 |
plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/app-editors/emacs-vcs/ChangeLog?rev=1.63&content-type=text/plain |
43 |
diff : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/app-editors/emacs-vcs/ChangeLog?r1=1.62&r2=1.63 |
44 |
|
45 |
Index: ChangeLog |
46 |
=================================================================== |
47 |
RCS file: /var/cvsroot/gentoo-x86/app-editors/emacs-vcs/ChangeLog,v |
48 |
retrieving revision 1.62 |
49 |
retrieving revision 1.63 |
50 |
diff -u -r1.62 -r1.63 |
51 |
--- ChangeLog 9 Sep 2011 19:21:18 -0000 1.62 |
52 |
+++ ChangeLog 26 Sep 2011 12:31:15 -0000 1.63 |
53 |
@@ -1,6 +1,14 @@ |
54 |
# ChangeLog for app-editors/emacs-vcs |
55 |
# Copyright 1999-2011 Gentoo Foundation; Distributed under the GPL v2 |
56 |
-# $Header: /var/cvsroot/gentoo-x86/app-editors/emacs-vcs/ChangeLog,v 1.62 2011/09/09 19:21:18 ulm Exp $ |
57 |
+# $Header: /var/cvsroot/gentoo-x86/app-editors/emacs-vcs/ChangeLog,v 1.63 2011/09/26 12:31:15 ulm Exp $ |
58 |
+ |
59 |
+*emacs-vcs-24.0.90 (26 Sep 2011) |
60 |
+ |
61 |
+ 26 Sep 2011; Ulrich Mueller <ulm@g.o> emacs-vcs-23.3.9999.ebuild, |
62 |
+ +emacs-vcs-24.0.90.ebuild, emacs-vcs-24.0.9999-r1.ebuild: |
63 |
+ First pretest for Emacs 24.1. Merge changes from Emacs overlay: Link against |
64 |
+ libXaw with USE=athena. Change [ ] to [[ ]] throughout. Remove outdated |
65 |
+ warning. |
66 |
|
67 |
09 Sep 2011; Ulrich Mueller <ulm@g.o> emacs-vcs-23.3.9999.ebuild: |
68 |
Merge changes from Emacs overlay. |
69 |
|
70 |
|
71 |
|
72 |
1.17 app-editors/emacs-vcs/emacs-vcs-24.0.9999-r1.ebuild |
73 |
|
74 |
file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/app-editors/emacs-vcs/emacs-vcs-24.0.9999-r1.ebuild?rev=1.17&view=markup |
75 |
plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/app-editors/emacs-vcs/emacs-vcs-24.0.9999-r1.ebuild?rev=1.17&content-type=text/plain |
76 |
diff : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/app-editors/emacs-vcs/emacs-vcs-24.0.9999-r1.ebuild?r1=1.16&r2=1.17 |
77 |
|
78 |
Index: emacs-vcs-24.0.9999-r1.ebuild |
79 |
=================================================================== |
80 |
RCS file: /var/cvsroot/gentoo-x86/app-editors/emacs-vcs/emacs-vcs-24.0.9999-r1.ebuild,v |
81 |
retrieving revision 1.16 |
82 |
retrieving revision 1.17 |
83 |
diff -u -r1.16 -r1.17 |
84 |
--- emacs-vcs-24.0.9999-r1.ebuild 22 Aug 2011 19:31:26 -0000 1.16 |
85 |
+++ emacs-vcs-24.0.9999-r1.ebuild 26 Sep 2011 12:31:15 -0000 1.17 |
86 |
@@ -1,12 +1,12 @@ |
87 |
# Copyright 1999-2011 Gentoo Foundation |
88 |
# Distributed under the terms of the GNU General Public License v2 |
89 |
-# $Header: /var/cvsroot/gentoo-x86/app-editors/emacs-vcs/emacs-vcs-24.0.9999-r1.ebuild,v 1.16 2011/08/22 19:31:26 ulm Exp $ |
90 |
+# $Header: /var/cvsroot/gentoo-x86/app-editors/emacs-vcs/emacs-vcs-24.0.9999-r1.ebuild,v 1.17 2011/09/26 12:31:15 ulm Exp $ |
91 |
|
92 |
EAPI=4 |
93 |
|
94 |
inherit autotools elisp-common eutils flag-o-matic multilib |
95 |
|
96 |
-if [ "${PV##*.}" = "9999" ]; then |
97 |
+if [[ ${PV##*.} = 9999 ]]; then |
98 |
EBZR_PROJECT="emacs" |
99 |
EBZR_BRANCH="trunk" |
100 |
EBZR_REPO_URI="bzr://bzr.savannah.gnu.org/emacs/${EBZR_BRANCH}/" |
101 |
@@ -30,7 +30,7 @@ |
102 |
LICENSE="GPL-3 FDL-1.3 BSD as-is MIT W3C unicode PSF-2" |
103 |
SLOT="24" |
104 |
KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~x86-fbsd ~amd64-linux ~x86-linux ~ppc-macos ~x86-macos" |
105 |
-IUSE="alsa dbus gconf gif gnutls gpm gsettings gtk gtk3 gzip-el hesiod imagemagick jpeg kerberos libxml2 m17n-lib motif png selinux sound source svg tiff toolkit-scroll-bars wide-int X Xaw3d xft +xpm" |
106 |
+IUSE="alsa athena dbus gconf gif gnutls gpm gsettings gtk gtk3 gzip-el hesiod imagemagick jpeg kerberos libxml2 m17n-lib motif png selinux sound source svg tiff toolkit-scroll-bars wide-int X Xaw3d xft +xpm" |
107 |
|
108 |
RDEPEND="sys-libs/ncurses |
109 |
>=app-admin/eselect-emacs-1.2 |
110 |
@@ -71,7 +71,10 @@ |
111 |
) |
112 |
!gtk? ( |
113 |
Xaw3d? ( x11-libs/libXaw3d ) |
114 |
- !Xaw3d? ( motif? ( >=x11-libs/openmotif-2.3:0 ) ) |
115 |
+ !Xaw3d? ( |
116 |
+ athena? ( x11-libs/libXaw ) |
117 |
+ !athena? ( motif? ( >=x11-libs/openmotif-2.3:0 ) ) |
118 |
+ ) |
119 |
) |
120 |
)" |
121 |
|
122 |
@@ -85,20 +88,11 @@ |
123 |
EMACS_SUFFIX="emacs-${SLOT}" |
124 |
SITEFILE="20${PN}-${SLOT}-gentoo.el" |
125 |
|
126 |
-pkg_setup() { |
127 |
- local olddir="${EBZR_STORE_DIR}/emacs-${EBZR_BRANCH#emacs-}" |
128 |
- if [ -d "${olddir}" ]; then |
129 |
- ewarn "bzr.eclass uses branches instead of checkouts now." |
130 |
- ewarn "Therefore, you may remove the old bzr checkout:" |
131 |
- ewarn "rm -rf ${olddir}" |
132 |
- fi |
133 |
-} |
134 |
- |
135 |
src_prepare() { |
136 |
- if [ "${PV##*.}" = "9999" ]; then |
137 |
+ if [[ ${PV##*.} = 9999 ]]; then |
138 |
FULL_VERSION=$(sed -n 's/^AC_INIT(emacs,[ \t]*\([^ \t,)]*\).*/\1/p' \ |
139 |
configure.in) |
140 |
- [ "${FULL_VERSION}" ] || die "Cannot determine current Emacs version" |
141 |
+ [[ ${FULL_VERSION} ]] || die "Cannot determine current Emacs version" |
142 |
echo |
143 |
einfo "Emacs branch: ${EBZR_BRANCH}" |
144 |
einfo "Revision: ${EBZR_REVISION:-${EBZR_REVNO}}" |
145 |
@@ -173,16 +167,11 @@ |
146 |
fi |
147 |
|
148 |
if use gtk; then |
149 |
- if use gtk3; then |
150 |
- einfo "Configuring to build with GIMP Toolkit (GTK+ 3)" |
151 |
- myconf="${myconf} --with-x-toolkit=gtk3" |
152 |
- else |
153 |
- einfo "Configuring to build with GIMP Toolkit (GTK+ 2)" |
154 |
- myconf="${myconf} --with-x-toolkit=gtk" |
155 |
- fi |
156 |
- elif use Xaw3d; then |
157 |
- einfo "Configuring to build with Xaw3d (Athena/Lucid) toolkit" |
158 |
- myconf="${myconf} --with-x-toolkit=lucid" |
159 |
+ einfo "Configuring to build with GIMP Toolkit (GTK+)" |
160 |
+ myconf="${myconf} --with-x-toolkit=$(usev gtk3 || echo gtk)" |
161 |
+ elif use Xaw3d || use athena; then |
162 |
+ einfo "Configuring to build with Athena/Lucid toolkit" |
163 |
+ myconf="${myconf} --with-x-toolkit=lucid $(use_with Xaw3d xaw3d)" |
164 |
elif use motif; then |
165 |
einfo "Configuring to build with Motif toolkit" |
166 |
myconf="${myconf} --with-x-toolkit=motif" |
167 |
@@ -192,9 +181,9 @@ |
168 |
fi |
169 |
|
170 |
local f tk= |
171 |
- for f in gtk Xaw3d motif; do |
172 |
+ for f in gtk Xaw3d athena motif; do |
173 |
use ${f} || continue |
174 |
- [ "${tk}" ] \ |
175 |
+ [[ ${tk} ]] \ |
176 |
&& ewarn "USE flag \"${f}\" ignored (superseded by \"${tk}\")" |
177 |
tk="${tk}${tk:+ }${f}" |
178 |
done |
179 |
@@ -202,7 +191,7 @@ |
180 |
myconf="${myconf} --without-x" |
181 |
fi |
182 |
|
183 |
- if [ "${PV##*.}" = "9999" ]; then |
184 |
+ if [[ ${PV##*.} = 9999 ]]; then |
185 |
# These variables are not needed for building. We add them to |
186 |
# configure options because they are stored in the Emacs binary |
187 |
# and available in variable "system-configuration-options". |
188 |
@@ -233,7 +222,7 @@ |
189 |
|
190 |
src_compile() { |
191 |
export SANDBOX_ON=0 # for the unbelievers, see Bug #131505 |
192 |
- if [ "${PV##*.}" = "9999" ]; then |
193 |
+ if [[ ${PV##*.} = 9999 ]]; then |
194 |
emake CC="$(tc-getCC)" bootstrap |
195 |
# cleanup, otherwise emacs will be dumped again in src_install |
196 |
(cd src; emake versionclean) |
197 |
@@ -305,7 +294,7 @@ |
198 |
pkg_preinst() { |
199 |
# move Info dir file to correct name |
200 |
local infodir=/usr/share/info/${EMACS_SUFFIX} f |
201 |
- if [ -f "${ED}"${infodir}/dir.orig ]; then |
202 |
+ if [[ -f ${ED}${infodir}/dir.orig ]]; then |
203 |
mv "${ED}"${infodir}/dir{.orig,} || die "moving info dir failed" |
204 |
else |
205 |
# this should not happen in EAPI 4 |
206 |
@@ -323,7 +312,7 @@ |
207 |
pkg_postinst() { |
208 |
local f |
209 |
for f in "${EROOT}"/var/lib/games/emacs/{snake,tetris}-scores; do |
210 |
- [ -e "${f}" ] || touch "${f}" |
211 |
+ [[ -e ${f} ]] || touch "${f}" |
212 |
done |
213 |
chown "${GAMES_USER_DED:-games}" "${EROOT}"/var/lib/games/emacs |
214 |
|
215 |
|
216 |
|
217 |
|
218 |
1.13 app-editors/emacs-vcs/emacs-vcs-23.3.9999.ebuild |
219 |
|
220 |
file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/app-editors/emacs-vcs/emacs-vcs-23.3.9999.ebuild?rev=1.13&view=markup |
221 |
plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/app-editors/emacs-vcs/emacs-vcs-23.3.9999.ebuild?rev=1.13&content-type=text/plain |
222 |
diff : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/app-editors/emacs-vcs/emacs-vcs-23.3.9999.ebuild?r1=1.12&r2=1.13 |
223 |
|
224 |
Index: emacs-vcs-23.3.9999.ebuild |
225 |
=================================================================== |
226 |
RCS file: /var/cvsroot/gentoo-x86/app-editors/emacs-vcs/emacs-vcs-23.3.9999.ebuild,v |
227 |
retrieving revision 1.12 |
228 |
retrieving revision 1.13 |
229 |
diff -u -r1.12 -r1.13 |
230 |
--- emacs-vcs-23.3.9999.ebuild 9 Sep 2011 19:21:18 -0000 1.12 |
231 |
+++ emacs-vcs-23.3.9999.ebuild 26 Sep 2011 12:31:16 -0000 1.13 |
232 |
@@ -1,13 +1,12 @@ |
233 |
# Copyright 1999-2011 Gentoo Foundation |
234 |
# Distributed under the terms of the GNU General Public License v2 |
235 |
-# $Header: /var/cvsroot/gentoo-x86/app-editors/emacs-vcs/emacs-vcs-23.3.9999.ebuild,v 1.12 2011/09/09 19:21:18 ulm Exp $ |
236 |
- |
237 |
+# $Header: /var/cvsroot/gentoo-x86/app-editors/emacs-vcs/emacs-vcs-23.3.9999.ebuild,v 1.13 2011/09/26 12:31:16 ulm Exp $ |
238 |
EAPI=4 |
239 |
WANT_AUTOMAKE="none" |
240 |
|
241 |
inherit autotools elisp-common eutils flag-o-matic multilib |
242 |
|
243 |
-if [ "${PV##*.}" = "9999" ]; then |
244 |
+if [[ ${PV##*.} = 9999 ]]; then |
245 |
EBZR_PROJECT="emacs" |
246 |
EBZR_BRANCH="emacs-23" |
247 |
EBZR_REPO_URI="bzr://bzr.savannah.gnu.org/emacs/${EBZR_BRANCH}/" |
248 |
@@ -31,7 +30,7 @@ |
249 |
LICENSE="GPL-3 FDL-1.3 BSD as-is MIT W3C unicode PSF-2" |
250 |
SLOT="23" |
251 |
KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~x86-fbsd" |
252 |
-IUSE="alsa dbus gconf gif gpm gtk gzip-el hesiod jpeg kerberos m17n-lib motif png sound source svg tiff toolkit-scroll-bars X Xaw3d xft +xpm" |
253 |
+IUSE="alsa athena dbus gconf gif gpm gtk gzip-el hesiod jpeg kerberos m17n-lib motif png sound source svg tiff toolkit-scroll-bars X Xaw3d xft +xpm" |
254 |
|
255 |
RDEPEND="sys-libs/ncurses |
256 |
>=app-admin/eselect-emacs-1.2 |
257 |
@@ -64,7 +63,10 @@ |
258 |
gtk? ( x11-libs/gtk+:2 ) |
259 |
!gtk? ( |
260 |
Xaw3d? ( x11-libs/libXaw3d ) |
261 |
- !Xaw3d? ( motif? ( >=x11-libs/openmotif-2.3:0 ) ) |
262 |
+ !Xaw3d? ( |
263 |
+ athena? ( x11-libs/libXaw ) |
264 |
+ !athena? ( motif? ( >=x11-libs/openmotif-2.3:0 ) ) |
265 |
+ ) |
266 |
) |
267 |
)" |
268 |
|
269 |
@@ -78,20 +80,11 @@ |
270 |
EMACS_SUFFIX="emacs-${SLOT}-vcs" |
271 |
SITEFILE="20${PN}-${SLOT}-gentoo.el" |
272 |
|
273 |
-pkg_setup() { |
274 |
- local olddir="${EBZR_STORE_DIR}/emacs-${EBZR_BRANCH#emacs-}" |
275 |
- if [ -d "${olddir}" ]; then |
276 |
- ewarn "bzr.eclass uses branches instead of checkouts now." |
277 |
- ewarn "Therefore, you may remove the old bzr checkout:" |
278 |
- ewarn "rm -rf ${olddir}" |
279 |
- fi |
280 |
-} |
281 |
- |
282 |
src_prepare() { |
283 |
- if [ "${PV##*.}" = "9999" ]; then |
284 |
+ if [[ ${PV##*.} = 9999 ]]; then |
285 |
FULL_VERSION=$(grep 'defconst[ ]*emacs-version' lisp/version.el \ |
286 |
| sed -e 's/^[^"]*"\([^"]*\)".*$/\1/') |
287 |
- [ "${FULL_VERSION}" ] || die "Cannot determine current Emacs version" |
288 |
+ [[ ${FULL_VERSION} ]] || die "Cannot determine current Emacs version" |
289 |
echo |
290 |
einfo "Emacs branch: ${EBZR_BRANCH}" |
291 |
einfo "Revision: ${EBZR_REVISION:-${EBZR_REVNO}}" |
292 |
@@ -174,9 +167,9 @@ |
293 |
if use gtk; then |
294 |
einfo "Configuring to build with GIMP Toolkit (GTK+)" |
295 |
myconf="${myconf} --with-x-toolkit=gtk" |
296 |
- elif use Xaw3d; then |
297 |
- einfo "Configuring to build with Xaw3d (Athena/Lucid) toolkit" |
298 |
- myconf="${myconf} --with-x-toolkit=lucid" |
299 |
+ elif use Xaw3d || use athena; then |
300 |
+ einfo "Configuring to build with Athena/Lucid toolkit" |
301 |
+ myconf="${myconf} --with-x-toolkit=lucid $(use_with Xaw3d xaw3d)" |
302 |
elif use motif; then |
303 |
einfo "Configuring to build with Motif toolkit" |
304 |
myconf="${myconf} --with-x-toolkit=motif" |
305 |
@@ -186,9 +179,9 @@ |
306 |
fi |
307 |
|
308 |
local f tk= |
309 |
- for f in gtk Xaw3d motif; do |
310 |
+ for f in gtk Xaw3d athena motif; do |
311 |
use ${f} || continue |
312 |
- [ "${tk}" ] \ |
313 |
+ [[ ${tk} ]] \ |
314 |
&& ewarn "USE flag \"${f}\" ignored (superseded by \"${tk}\")" |
315 |
tk="${tk}${tk:+ }${f}" |
316 |
done |
317 |
@@ -196,7 +189,7 @@ |
318 |
myconf="${myconf} --without-x" |
319 |
fi |
320 |
|
321 |
- if [ "${PV##*.}" = "9999" ]; then |
322 |
+ if [[ ${PV##*.} = 9999 ]]; then |
323 |
# These variables are not needed for building. We add them to |
324 |
# configure options because they are stored in the Emacs binary |
325 |
# and available in variable "system-configuration-options". |
326 |
@@ -223,7 +216,7 @@ |
327 |
|
328 |
src_compile() { |
329 |
export SANDBOX_ON=0 # for the unbelievers, see Bug #131505 |
330 |
- if [ "${PV##*.}" = "9999" ]; then |
331 |
+ if [[ ${PV##*.} = 9999 ]]; then |
332 |
emake CC="$(tc-getCC)" bootstrap |
333 |
# cleanup, otherwise emacs will be dumped again in src_install |
334 |
(cd src; emake versionclean) |
335 |
@@ -295,7 +288,7 @@ |
336 |
pkg_preinst() { |
337 |
# move Info dir file to correct name |
338 |
local infodir=/usr/share/info/${EMACS_SUFFIX} f |
339 |
- if [ -f "${ED}"${infodir}/dir.orig ]; then |
340 |
+ if [[ -f ${ED}${infodir}/dir.orig ]]; then |
341 |
mv "${ED}"${infodir}/dir{.orig,} || die "moving info dir failed" |
342 |
else |
343 |
# this should not happen in EAPI 4 |
344 |
@@ -313,7 +306,7 @@ |
345 |
pkg_postinst() { |
346 |
local f |
347 |
for f in "${EROOT}"/var/lib/games/emacs/{snake,tetris}-scores; do |
348 |
- [ -e "${f}" ] || touch "${f}" |
349 |
+ [[ -e ${f} ]] || touch "${f}" |
350 |
done |
351 |
chown games "${EROOT}"/var/lib/games/emacs |
352 |
|
353 |
|
354 |
|
355 |
|
356 |
1.1 app-editors/emacs-vcs/emacs-vcs-24.0.90.ebuild |
357 |
|
358 |
file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/app-editors/emacs-vcs/emacs-vcs-24.0.90.ebuild?rev=1.1&view=markup |
359 |
plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/app-editors/emacs-vcs/emacs-vcs-24.0.90.ebuild?rev=1.1&content-type=text/plain |
360 |
|
361 |
Index: emacs-vcs-24.0.90.ebuild |
362 |
=================================================================== |
363 |
# Copyright 1999-2011 Gentoo Foundation |
364 |
# Distributed under the terms of the GNU General Public License v2 |
365 |
# $Header: /var/cvsroot/gentoo-x86/app-editors/emacs-vcs/emacs-vcs-24.0.90.ebuild,v 1.1 2011/09/26 12:31:16 ulm Exp $ |
366 |
|
367 |
EAPI=4 |
368 |
|
369 |
inherit autotools elisp-common eutils flag-o-matic multilib |
370 |
|
371 |
if [[ ${PV##*.} = 9999 ]]; then |
372 |
EBZR_PROJECT="emacs" |
373 |
EBZR_BRANCH="trunk" |
374 |
EBZR_REPO_URI="bzr://bzr.savannah.gnu.org/emacs/${EBZR_BRANCH}/" |
375 |
# "Nosmart" is much faster for initial branching. |
376 |
EBZR_INITIAL_URI="nosmart+${EBZR_REPO_URI}" |
377 |
inherit bzr |
378 |
SRC_URI="" |
379 |
else |
380 |
SRC_URI="mirror://gentoo/emacs-${PV}.tar.gz |
381 |
ftp://alpha.gnu.org/gnu/emacs/pretest/emacs-${PV}.tar.gz" |
382 |
# FULL_VERSION keeps the full version number, which is needed in |
383 |
# order to determine some path information correctly for copy/move |
384 |
# operations later on |
385 |
FULL_VERSION="${PV%%_*}" |
386 |
S="${WORKDIR}/emacs-${FULL_VERSION}" |
387 |
fi |
388 |
|
389 |
DESCRIPTION="The extensible, customizable, self-documenting real-time display editor" |
390 |
HOMEPAGE="http://www.gnu.org/software/emacs/" |
391 |
|
392 |
LICENSE="GPL-3 FDL-1.3 BSD as-is MIT W3C unicode PSF-2" |
393 |
SLOT="24" |
394 |
KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~x86-fbsd ~amd64-linux ~x86-linux ~ppc-macos ~x86-macos" |
395 |
IUSE="alsa athena dbus gconf gif gnutls gpm gsettings gtk gtk3 gzip-el hesiod imagemagick jpeg kerberos libxml2 m17n-lib motif png selinux sound source svg tiff toolkit-scroll-bars wide-int X Xaw3d xft +xpm" |
396 |
|
397 |
RDEPEND="sys-libs/ncurses |
398 |
>=app-admin/eselect-emacs-1.2 |
399 |
net-libs/liblockfile |
400 |
hesiod? ( net-dns/hesiod ) |
401 |
kerberos? ( virtual/krb5 ) |
402 |
alsa? ( media-libs/alsa-lib ) |
403 |
gpm? ( sys-libs/gpm ) |
404 |
dbus? ( sys-apps/dbus ) |
405 |
gnutls? ( net-libs/gnutls ) |
406 |
selinux? ( sys-libs/libselinux ) |
407 |
X? ( |
408 |
x11-libs/libXmu |
409 |
x11-libs/libXt |
410 |
x11-misc/xbitmaps |
411 |
gconf? ( >=gnome-base/gconf-2.26.2 ) |
412 |
gsettings? ( >=dev-libs/glib-2.28.6 ) |
413 |
libxml2? ( >=dev-libs/libxml2-2.2.0 ) |
414 |
gif? ( media-libs/giflib ) |
415 |
jpeg? ( virtual/jpeg ) |
416 |
png? ( media-libs/libpng ) |
417 |
svg? ( >=gnome-base/librsvg-2.0 ) |
418 |
tiff? ( media-libs/tiff ) |
419 |
xpm? ( x11-libs/libXpm ) |
420 |
imagemagick? ( >=media-gfx/imagemagick-6.6.2 ) |
421 |
xft? ( |
422 |
media-libs/fontconfig |
423 |
media-libs/freetype |
424 |
x11-libs/libXft |
425 |
m17n-lib? ( |
426 |
>=dev-libs/libotf-0.9.4 |
427 |
>=dev-libs/m17n-lib-1.5.1 |
428 |
) |
429 |
) |
430 |
gtk? ( |
431 |
gtk3? ( x11-libs/gtk+:3 ) |
432 |
!gtk3? ( x11-libs/gtk+:2 ) |
433 |
) |
434 |
!gtk? ( |
435 |
Xaw3d? ( x11-libs/libXaw3d ) |
436 |
!Xaw3d? ( |
437 |
athena? ( x11-libs/libXaw ) |
438 |
!athena? ( motif? ( >=x11-libs/openmotif-2.3:0 ) ) |
439 |
) |
440 |
) |
441 |
)" |
442 |
|
443 |
DEPEND="${RDEPEND} |
444 |
dev-util/pkgconfig |
445 |
gzip-el? ( app-arch/gzip )" |
446 |
|
447 |
RDEPEND="${RDEPEND} |
448 |
>=app-emacs/emacs-common-gentoo-1[X?]" |
449 |
|
450 |
EMACS_SUFFIX="emacs-${SLOT}" |
451 |
SITEFILE="20${PN}-${SLOT}-gentoo.el" |
452 |
|
453 |
src_prepare() { |
454 |
if [[ ${PV##*.} = 9999 ]]; then |
455 |
FULL_VERSION=$(sed -n 's/^AC_INIT(emacs,[ \t]*\([^ \t,)]*\).*/\1/p' \ |
456 |
configure.in) |
457 |
[[ ${FULL_VERSION} ]] || die "Cannot determine current Emacs version" |
458 |
echo |
459 |
einfo "Emacs branch: ${EBZR_BRANCH}" |
460 |
einfo "Revision: ${EBZR_REVISION:-${EBZR_REVNO}}" |
461 |
einfo "Emacs version number: ${FULL_VERSION}" |
462 |
[[ ${FULL_VERSION} =~ ^${PV%.*}(\..*)?$ ]] \ |
463 |
|| die "Upstream version number changed to ${FULL_VERSION}" |
464 |
echo |
465 |
fi |
466 |
|
467 |
if ! use alsa; then |
468 |
# ALSA is detected even if not requested by its USE flag. |
469 |
# Suppress it by supplying pkg-config with a wrong library name. |
470 |
sed -i -e "/ALSA_MODULES=/s/alsa/DiSaBlEaLsA/" configure.in \ |
471 |
|| die "unable to sed configure.in" |
472 |
fi |
473 |
if ! use gzip-el; then |
474 |
# Emacs' build system automatically detects the gzip binary and |
475 |
# compresses el files. We don't want that so confuse it with a |
476 |
# wrong binary name |
477 |
sed -i -e "s/ gzip/ PrEvEnTcOmPrEsSiOn/" configure.in \ |
478 |
|| die "unable to sed configure.in" |
479 |
fi |
480 |
|
481 |
AT_M4DIR=m4 eautoreconf |
482 |
} |
483 |
|
484 |
src_configure() { |
485 |
ALLOWED_FLAGS="" |
486 |
strip-flags |
487 |
|
488 |
if use sh; then |
489 |
replace-flags -O[1-9] -O0 #262359 |
490 |
elif use ia64; then |
491 |
replace-flags -O[2-9] -O1 #325373 |
492 |
else |
493 |
replace-flags -O[3-9] -O2 |
494 |
fi |
495 |
|
496 |
local myconf |
497 |
|
498 |
if use alsa && ! use sound; then |
499 |
echo |
500 |
einfo "Although sound USE flag is disabled you chose to have alsa," |
501 |
einfo "so sound is switched on anyway." |
502 |
echo |
503 |
myconf="${myconf} --with-sound" |
504 |
else |
505 |
myconf="${myconf} $(use_with sound)" |
506 |
fi |
507 |
|
508 |
if use X; then |
509 |
myconf="${myconf} --with-x" |
510 |
myconf="${myconf} $(use_with gconf)" |
511 |
myconf="${myconf} $(use_with gsettings)" |
512 |
myconf="${myconf} $(use_with libxml2 xml2)" |
513 |
myconf="${myconf} $(use_with toolkit-scroll-bars)" |
514 |
myconf="${myconf} $(use_with wide-int)" |
515 |
myconf="${myconf} $(use_with gif) $(use_with jpeg)" |
516 |
myconf="${myconf} $(use_with png) $(use_with svg rsvg)" |
517 |
myconf="${myconf} $(use_with tiff) $(use_with xpm)" |
518 |
myconf="${myconf} $(use_with imagemagick)" |
519 |
|
520 |
if use xft; then |
521 |
myconf="${myconf} --with-xft" |
522 |
myconf="${myconf} $(use_with m17n-lib libotf)" |
523 |
myconf="${myconf} $(use_with m17n-lib m17n-flt)" |
524 |
else |
525 |
myconf="${myconf} --without-xft" |
526 |
myconf="${myconf} --without-libotf --without-m17n-flt" |
527 |
use m17n-lib && ewarn \ |
528 |
"USE flag \"m17n-lib\" has no effect if \"xft\" is not set." |
529 |
fi |
530 |
|
531 |
if use gtk; then |
532 |
einfo "Configuring to build with GIMP Toolkit (GTK+)" |
533 |
myconf="${myconf} --with-x-toolkit=$(usev gtk3 || echo gtk)" |
534 |
elif use Xaw3d || use athena; then |
535 |
einfo "Configuring to build with Athena/Lucid toolkit" |
536 |
myconf="${myconf} --with-x-toolkit=lucid $(use_with Xaw3d xaw3d)" |
537 |
elif use motif; then |
538 |
einfo "Configuring to build with Motif toolkit" |
539 |
myconf="${myconf} --with-x-toolkit=motif" |
540 |
else |
541 |
einfo "Configuring to build with no toolkit" |
542 |
myconf="${myconf} --with-x-toolkit=no" |
543 |
fi |
544 |
|
545 |
local f tk= |
546 |
for f in gtk Xaw3d athena motif; do |
547 |
use ${f} || continue |
548 |
[[ ${tk} ]] \ |
549 |
&& ewarn "USE flag \"${f}\" ignored (superseded by \"${tk}\")" |
550 |
tk="${tk}${tk:+ }${f}" |
551 |
done |
552 |
else |
553 |
myconf="${myconf} --without-x" |
554 |
fi |
555 |
|
556 |
if [[ ${PV##*.} = 9999 ]]; then |
557 |
# These variables are not needed for building. We add them to |
558 |
# configure options because they are stored in the Emacs binary |
559 |
# and available in variable "system-configuration-options". |
560 |
myconf="${myconf} EBZR_BRANCH=${EBZR_BRANCH} EBZR_REVNO=${EBZR_REVNO}" |
561 |
fi |
562 |
|
563 |
# According to configure, this option is only used for GNU/Linux |
564 |
# (x86_64 and s390). For Gentoo Prefix we have to explicitly spell |
565 |
# out the location because $(get_libdir) does not necessarily return |
566 |
# something that matches the host OS's libdir naming (e.g. RHEL). |
567 |
local crtdir=$($(tc-getCC) -print-file-name=crt1.o) |
568 |
crtdir=${crtdir%/*} |
569 |
|
570 |
econf \ |
571 |
--program-suffix=-${EMACS_SUFFIX} \ |
572 |
--infodir="${EPREFIX}"/usr/share/info/${EMACS_SUFFIX} \ |
573 |
--with-crt-dir="${crtdir}" \ |
574 |
--with-gameuser="${GAMES_USER_DED:-games}" \ |
575 |
--without-compress-info \ |
576 |
$(use_with hesiod) \ |
577 |
$(use_with kerberos) $(use_with kerberos kerberos5) \ |
578 |
$(use_with gpm) \ |
579 |
$(use_with dbus) \ |
580 |
$(use_with gnutls) \ |
581 |
$(use_with selinux) \ |
582 |
${myconf} |
583 |
} |
584 |
|
585 |
src_compile() { |
586 |
export SANDBOX_ON=0 # for the unbelievers, see Bug #131505 |
587 |
if [[ ${PV##*.} = 9999 ]]; then |
588 |
emake CC="$(tc-getCC)" bootstrap |
589 |
# cleanup, otherwise emacs will be dumped again in src_install |
590 |
(cd src; emake versionclean) |
591 |
fi |
592 |
# set last component of emacs-version to (package revision + 1) |
593 |
touch src/emacs-${FULL_VERSION}.${PR#r} |
594 |
emake CC="$(tc-getCC)" |
595 |
} |
596 |
|
597 |
src_install () { |
598 |
local i m |
599 |
|
600 |
emake install DESTDIR="${D}" |
601 |
|
602 |
rm "${ED}"/usr/bin/emacs-${FULL_VERSION}-${EMACS_SUFFIX} \ |
603 |
|| die "removing duplicate emacs executable failed" |
604 |
mv "${ED}"/usr/bin/emacs-${EMACS_SUFFIX} "${ED}"/usr/bin/${EMACS_SUFFIX} \ |
605 |
|| die "moving Emacs executable failed" |
606 |
|
607 |
# move man pages to the correct place |
608 |
for m in "${ED}"/usr/share/man/man1/* ; do |
609 |
mv "${m}" "${m%.1}-${EMACS_SUFFIX}.1" || die "mv man failed" |
610 |
done |
611 |
|
612 |
# move info dir to avoid collisions with the dir file generated by portage |
613 |
mv "${ED}"/usr/share/info/${EMACS_SUFFIX}/dir{,.orig} \ |
614 |
|| die "moving info dir failed" |
615 |
touch "${ED}"/usr/share/info/${EMACS_SUFFIX}/.keepinfodir |
616 |
docompress -x /usr/share/info/${EMACS_SUFFIX}/dir.orig |
617 |
|
618 |
# avoid collision between slots, see bug #169033 e.g. |
619 |
rm "${ED}"/usr/share/emacs/site-lisp/subdirs.el |
620 |
rm -rf "${ED}"/usr/share/{applications,icons} |
621 |
rm "${ED}"/var/lib/games/emacs/{snake,tetris}-scores |
622 |
keepdir /var/lib/games/emacs |
623 |
|
624 |
local c=";;" |
625 |
if use source; then |
626 |
insinto /usr/share/emacs/${FULL_VERSION}/src |
627 |
# This is not meant to install all the source -- just the |
628 |
# C source you might find via find-function |
629 |
doins src/*.[ch] |
630 |
c="" |
631 |
fi |
632 |
|
633 |
sed 's/^X//' >"${T}/${SITEFILE}" <<-EOF |
634 |
X |
635 |
;;; ${PN}-${SLOT} site-lisp configuration |
636 |
X |
637 |
(when (string-match "\\\\\`${FULL_VERSION//./\\\\.}\\\\>" emacs-version) |
638 |
X ${c}(setq find-function-C-source-directory |
639 |
X ${c} "${EPREFIX}/usr/share/emacs/${FULL_VERSION}/src") |
640 |
X (let ((path (getenv "INFOPATH")) |
641 |
X (dir "${EPREFIX}/usr/share/info/${EMACS_SUFFIX}") |
642 |
X (re "\\\\\`${EPREFIX}/usr/share/info\\\\>")) |
643 |
X (and path |
644 |
X ;; move Emacs Info dir before anything else in /usr/share/info |
645 |
X (let* ((p (cons nil (split-string path ":" t))) (q p)) |
646 |
X (while (and (cdr q) (not (string-match re (cadr q)))) |
647 |
X (setq q (cdr q))) |
648 |
X (setcdr q (cons dir (delete dir (cdr q)))) |
649 |
X (setq Info-directory-list (prune-directory-list (cdr p))))))) |
650 |
EOF |
651 |
elisp-site-file-install "${T}/${SITEFILE}" || die |
652 |
|
653 |
dodoc README BUGS |
654 |
} |
655 |
|
656 |
pkg_preinst() { |
657 |
# move Info dir file to correct name |
658 |
local infodir=/usr/share/info/${EMACS_SUFFIX} f |
659 |
if [[ -f ${ED}${infodir}/dir.orig ]]; then |
660 |
mv "${ED}"${infodir}/dir{.orig,} || die "moving info dir failed" |
661 |
else |
662 |
# this should not happen in EAPI 4 |
663 |
ewarn "Regenerating Info directory index in ${infodir} ..." |
664 |
rm -f "${ED}"${infodir}/dir{,.*} |
665 |
for f in "${ED}"${infodir}/*; do |
666 |
if [[ ${f##*/} != *-[0-9]* && -e ${f} ]]; then |
667 |
install-info --info-dir="${ED}"${infodir} "${f}" \ |
668 |
|| die "install-info failed" |
669 |
fi |
670 |
done |
671 |
fi |
672 |
} |
673 |
|
674 |
pkg_postinst() { |
675 |
local f |
676 |
for f in "${EROOT}"/var/lib/games/emacs/{snake,tetris}-scores; do |
677 |
[[ -e ${f} ]] || touch "${f}" |
678 |
done |
679 |
chown "${GAMES_USER_DED:-games}" "${EROOT}"/var/lib/games/emacs |
680 |
|
681 |
elisp-site-regen |
682 |
eselect emacs update ifunset |
683 |
|
684 |
if use X; then |
685 |
echo |
686 |
elog "You need to install some fonts for Emacs." |
687 |
elog "Installing media-fonts/font-adobe-{75,100}dpi on the X server's" |
688 |
elog "machine would satisfy basic Emacs requirements under X11." |
689 |
elog "See also http://www.gentoo.org/proj/en/lisp/emacs/xft.xml" |
690 |
elog "for how to enable anti-aliased fonts." |
691 |
fi |
692 |
|
693 |
echo |
694 |
elog "You can set the version to be started by /usr/bin/emacs through" |
695 |
elog "the Emacs eselect module, which also redirects man and info pages." |
696 |
elog "Therefore, several Emacs versions can be installed at the same time." |
697 |
elog "\"man emacs.eselect\" for details." |
698 |
echo |
699 |
elog "If you upgrade from a previous major version of Emacs, then it is" |
700 |
elog "strongly recommended that you use app-admin/emacs-updater to rebuild" |
701 |
elog "all byte-compiled elisp files of the installed Emacs packages." |
702 |
} |
703 |
|
704 |
pkg_postrm() { |
705 |
elisp-site-regen |
706 |
eselect emacs update ifunset |
707 |
} |