Gentoo Archives: gentoo-commits

From: "Ulrich Müller" <ulm@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: app-editors/emacs/
Date: Mon, 22 Aug 2016 08:23:10
Message-Id: 1471853988.9023ef48b1a09e4a9029668d229ab99423a85563.ulm@gentoo
1 commit: 9023ef48b1a09e4a9029668d229ab99423a85563
2 Author: Ulrich Müller <ulm <AT> gentoo <DOT> org>
3 AuthorDate: Mon Aug 22 08:19:48 2016 +0000
4 Commit: Ulrich Müller <ulm <AT> gentoo <DOT> org>
5 CommitDate: Mon Aug 22 08:19:48 2016 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=9023ef48
7
8 app-editors/emacs: Version bump.
9
10 Package-Manager: portage-2.3.0
11
12 app-editors/emacs/Manifest | 1 +
13 app-editors/emacs/emacs-25.1_rc2.ebuild | 358 ++++++++++++++++++++++++++++++++
14 2 files changed, 359 insertions(+)
15
16 diff --git a/app-editors/emacs/Manifest b/app-editors/emacs/Manifest
17 index 3ea79d3..e0f9d67 100644
18 --- a/app-editors/emacs/Manifest
19 +++ b/app-editors/emacs/Manifest
20 @@ -9,3 +9,4 @@ DIST emacs-24.5-patches-1.tar.xz 3744 SHA256 dbcad232dff47e5540fff33351d76a92165
21 DIST emacs-24.5-patches-2.tar.xz 11876 SHA256 16c313ed0fe718cc8505d4276d0b8b18564db5a96745b215c42e21f062a91f9e SHA512 58efc75749842738c6585f7d39d79dee6ef030f589341b4cce6d02623173384f84e1005a7de27be6f759a564ce762dd472c6061579a16a63916b3dfa711697de WHIRLPOOL 41eaaae10df709b28c1f9dae442d59b62281b92e622efb7dbfd62625814338e64dbf116a2373d136637e12461c15133c02bd3dd76c7a7236f53a715a973eb292
22 DIST emacs-24.5.tar.xz 39759804 SHA256 dd47d71dd2a526cf6b47cb49af793ec2e26af69a0951cc40e43ae290eacfc34e SHA512 89dee4c3aadb6e505c523f84c65b5e40e5bf28a586cc8a4518a59581c22972f942bb6f3c772df0d5b2685c3e78247c545c6bb2576e981d1ef0f9298c18ad1677 WHIRLPOOL 3d9f8fb840f4c846246e642369f967ba0ec357c7cf718ed865523a3cd39605ba14b8c15fc9ae3f076c27e5b6e41fcb681d15f1c6ffc5934430c0a2bf47c233a3
23 DIST emacs-25.1-rc1.tar.xz 42309372 SHA256 c00c50e66474359d1e24baa2a0703bc64207caffc31d0808d8b4ffa4b3826133 SHA512 c8e101d5fef07cc31ce10a0cc133d68b763a19f859dc2b06e05e72b566158c7c5eb5250d4736fdcab88fbdb5f8e279456c4f3f65491a1609cc5f1e8479be853a WHIRLPOOL 3cbdfa87132c6e043e975b983cfe9fe04676119ba61eff4f0b596978c26bbd721c911b1e90f59ed838d56db63faada28d4048be24a3f9ac05f96ff12b25d0781
24 +DIST emacs-25.1-rc2.tar.xz 42317560 SHA256 5bd45f03bdff90f9d7add7224917fc828ed89716e952b3db8eb98242b7dfcec1 SHA512 02d2c48d7b7cd56f35b9d66c7b5be2acc6475e3b780069e65b5dcb81789343637b5802e52867417238778f96dcd6cbb2e804ad411283313f70d25010102cf0a1 WHIRLPOOL 9ea4b6f01933701934d4d21b85d3085b8d7cf8793fd977fe19f46902e6b2b45cec1142f9decc87691bf19e94616f5727e88b962f4945cb713483a865553b169e
25
26 diff --git a/app-editors/emacs/emacs-25.1_rc2.ebuild b/app-editors/emacs/emacs-25.1_rc2.ebuild
27 new file mode 100644
28 index 0000000..7894ed8
29 --- /dev/null
30 +++ b/app-editors/emacs/emacs-25.1_rc2.ebuild
31 @@ -0,0 +1,358 @@
32 +# Copyright 1999-2016 Gentoo Foundation
33 +# Distributed under the terms of the GNU General Public License v2
34 +# $Id$
35 +
36 +EAPI=6
37 +
38 +inherit elisp-common flag-o-matic multilib readme.gentoo-r1
39 +
40 +DESCRIPTION="The extensible, customizable, self-documenting real-time display editor"
41 +HOMEPAGE="https://www.gnu.org/software/emacs/"
42 +SRC_URI="mirror://gnu-alpha/emacs/pretest/emacs-${PV/_/-}.tar.xz"
43 +
44 +LICENSE="GPL-3+ FDL-1.3+ BSD HPND MIT W3C unicode PSF-2"
45 +SLOT="25"
46 +KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~amd64-fbsd ~x86-fbsd ~x86-freebsd ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos"
47 +IUSE="acl alsa aqua athena cairo dbus games gconf gfile gif gpm gsettings gtk +gtk3 gzip-el hesiod imagemagick +inotify jpeg kerberos libxml2 livecd m17n-lib motif pax_kernel png selinux sound source ssl svg tiff toolkit-scroll-bars wide-int X Xaw3d xft +xpm xwidgets zlib"
48 +REQUIRED_USE="?? ( aqua X )"
49 +
50 +RDEPEND="sys-libs/ncurses:0
51 + >=app-eselect/eselect-emacs-1.16
52 + >=app-emacs/emacs-common-gentoo-1.5[games?,X?]
53 + net-libs/liblockfile
54 + acl? ( virtual/acl )
55 + alsa? ( media-libs/alsa-lib )
56 + dbus? ( sys-apps/dbus )
57 + gpm? ( sys-libs/gpm )
58 + hesiod? ( net-dns/hesiod )
59 + !inotify? ( gfile? ( >=dev-libs/glib-2.28.6 ) )
60 + kerberos? ( virtual/krb5 )
61 + libxml2? ( >=dev-libs/libxml2-2.2.0 )
62 + selinux? ( sys-libs/libselinux )
63 + ssl? ( net-libs/gnutls )
64 + zlib? ( sys-libs/zlib )
65 + X? (
66 + x11-libs/libXmu
67 + x11-libs/libXt
68 + x11-misc/xbitmaps
69 + gconf? ( >=gnome-base/gconf-2.26.2 )
70 + gsettings? ( >=dev-libs/glib-2.28.6 )
71 + gif? ( media-libs/giflib:0= )
72 + jpeg? ( virtual/jpeg:0= )
73 + png? ( >=media-libs/libpng-1.4:0= )
74 + svg? ( >=gnome-base/librsvg-2.0 )
75 + tiff? ( media-libs/tiff:0 )
76 + xpm? ( x11-libs/libXpm )
77 + imagemagick? ( >=media-gfx/imagemagick-6.6.2 )
78 + xft? (
79 + media-libs/fontconfig
80 + media-libs/freetype
81 + x11-libs/libXft
82 + cairo? ( >=x11-libs/cairo-1.12.18 )
83 + m17n-lib? (
84 + >=dev-libs/libotf-0.9.4
85 + >=dev-libs/m17n-lib-1.5.1
86 + )
87 + )
88 + gtk? (
89 + xwidgets? (
90 + x11-libs/gtk+:3
91 + net-libs/webkit-gtk:3=
92 + )
93 + !xwidgets? (
94 + gtk3? ( x11-libs/gtk+:3 )
95 + !gtk3? ( x11-libs/gtk+:2 )
96 + )
97 + )
98 + !gtk? (
99 + motif? ( >=x11-libs/motif-2.3:0 )
100 + !motif? (
101 + Xaw3d? ( x11-libs/libXaw3d )
102 + !Xaw3d? ( athena? ( x11-libs/libXaw ) )
103 + )
104 + )
105 + )"
106 +
107 +DEPEND="${RDEPEND}
108 + virtual/pkgconfig
109 + gzip-el? ( app-arch/gzip )
110 + pax_kernel? (
111 + sys-apps/attr
112 + sys-apps/paxctl
113 + )"
114 +
115 +RDEPEND="${RDEPEND}
116 + !<app-editors/emacs-vcs-${PV}"
117 +
118 +EMACS_SUFFIX="${PN/emacs/emacs-${SLOT}}"
119 +SITEFILE="20${PN}-${SLOT}-gentoo.el"
120 +# FULL_VERSION keeps the full version number, which is needed in
121 +# order to determine some path information correctly for copy/move
122 +# operations later on
123 +FULL_VERSION="${PV%%_*}"
124 +S="${WORKDIR}/emacs-${FULL_VERSION}"
125 +
126 +src_prepare() {
127 + eapply_user
128 +
129 + # Fix filename reference in redirected man page
130 + sed -i -e "/^\\.so/s/etags/&-${EMACS_SUFFIX}/" doc/man/ctags.1 \
131 + || die "unable to sed ctags.1"
132 +
133 + #AT_M4DIR=m4 eautoreconf
134 +}
135 +
136 +src_configure() {
137 + strip-flags
138 + filter-flags -pie #526948
139 +
140 + if use sh; then
141 + replace-flags "-O[1-9]" -O0 #262359
142 + elif use ia64; then
143 + replace-flags "-O[2-9]" -O1 #325373
144 + else
145 + replace-flags "-O[3-9]" -O2
146 + fi
147 +
148 + local myconf
149 +
150 + if use alsa; then
151 + use sound || ewarn \
152 + "USE flag \"alsa\" overrides \"-sound\"; enabling sound support."
153 + myconf+=" --with-sound=alsa"
154 + else
155 + myconf+=" --with-sound=$(usex sound oss)"
156 + fi
157 +
158 + if use X; then
159 + myconf+=" --with-x --without-ns"
160 + myconf+=" $(use_with gconf)"
161 + myconf+=" $(use_with gsettings)"
162 + myconf+=" $(use_with toolkit-scroll-bars)"
163 + myconf+=" $(use_with gif)"
164 + myconf+=" $(use_with jpeg)"
165 + myconf+=" $(use_with png)"
166 + myconf+=" $(use_with svg rsvg)"
167 + myconf+=" $(use_with tiff)"
168 + myconf+=" $(use_with xpm)"
169 + myconf+=" $(use_with imagemagick)"
170 +
171 + if use xft; then
172 + myconf+=" --with-xft"
173 + myconf+=" $(use_with cairo)"
174 + myconf+=" $(use_with m17n-lib libotf)"
175 + myconf+=" $(use_with m17n-lib m17n-flt)"
176 + else
177 + myconf+=" --without-xft"
178 + myconf+=" --without-cairo"
179 + myconf+=" --without-libotf --without-m17n-flt"
180 + use cairo && ewarn \
181 + "USE flag \"cairo\" has no effect if \"xft\" is not set."
182 + use m17n-lib && ewarn \
183 + "USE flag \"m17n-lib\" has no effect if \"xft\" is not set."
184 + fi
185 +
186 + local f
187 + if use gtk; then
188 + einfo "Configuring to build with GIMP Toolkit (GTK+)"
189 + while read line; do ewarn "${line}"; done <<-EOF
190 + Your version of GTK+ will have problems with closing open
191 + displays. This is no problem if you just use one display, but
192 + if you use more than one and close one of them Emacs may crash.
193 + See <https://bugzilla.gnome.org/show_bug.cgi?id=85715>.
194 + If you intend to use more than one display, then it is strongly
195 + recommended that you compile Emacs with the Athena/Lucid or the
196 + Motif toolkit instead.
197 + EOF
198 + if use xwidgets; then
199 + myconf+=" --with-x-toolkit=gtk3 --with-xwidgets"
200 + else
201 + myconf+=" --with-x-toolkit=$(usex gtk3 gtk3 gtk2)"
202 + myconf+=" --without-xwidgets"
203 + fi
204 + for f in motif Xaw3d athena; do
205 + use ${f} && ewarn \
206 + "USE flag \"${f}\" has no effect if \"gtk\" is set."
207 + done
208 + elif use motif; then
209 + einfo "Configuring to build with Motif toolkit"
210 + myconf+=" --with-x-toolkit=motif"
211 + for f in Xaw3d athena; do
212 + use ${f} && ewarn \
213 + "USE flag \"${f}\" has no effect if \"motif\" is set."
214 + done
215 + elif use athena || use Xaw3d; then
216 + einfo "Configuring to build with Athena/Lucid toolkit"
217 + myconf+=" --with-x-toolkit=lucid $(use_with Xaw3d xaw3d)"
218 + else
219 + einfo "Configuring to build with no toolkit"
220 + myconf+=" --with-x-toolkit=no"
221 + fi
222 + ! use gtk && use xwidgets && ewarn \
223 + "USE flag \"xwidgets\" has no effect if \"gtk\" is not set."
224 + elif use aqua; then
225 + einfo "Configuring to build with Nextstep (Cocoa) support"
226 + myconf+=" --with-ns --disable-ns-self-contained"
227 + myconf+=" --without-x"
228 + else
229 + myconf+=" --without-x --without-ns"
230 + fi
231 +
232 + # Save version information in the Emacs binary. It will be available
233 + # in variable "system-configuration-options".
234 + myconf+=" GENTOO_PACKAGE=${CATEGORY}/${PF}"
235 +
236 + econf \
237 + --program-suffix="-${EMACS_SUFFIX}" \
238 + --infodir="${EPREFIX}"/usr/share/info/${EMACS_SUFFIX} \
239 + --localstatedir="${EPREFIX}"/var \
240 + --enable-locallisppath="${EPREFIX}/etc/emacs:${EPREFIX}${SITELISP}" \
241 + --with-gameuser=":gamestat" \
242 + --without-compress-install \
243 + --with-file-notification=$(usev inotify || usev gfile || echo no) \
244 + $(use_enable acl) \
245 + $(use_with dbus) \
246 + $(use_with gpm) \
247 + $(use_with hesiod) \
248 + $(use_with kerberos) $(use_with kerberos kerberos5) \
249 + $(use_with libxml2 xml2) \
250 + $(use_with selinux) \
251 + $(use_with ssl gnutls) \
252 + $(use_with wide-int) \
253 + $(use_with zlib) \
254 + ${myconf}
255 +}
256 +
257 +src_compile() {
258 + export SANDBOX_ON=0 # for the unbelievers, see Bug #131505
259 + emake
260 +}
261 +
262 +src_install () {
263 + emake DESTDIR="${D}" NO_BIN_LINK=t install
264 +
265 + mv "${ED}"/usr/bin/{emacs-${FULL_VERSION}-,}${EMACS_SUFFIX} \
266 + || die "moving emacs executable failed"
267 + mv "${ED}"/usr/share/man/man1/{emacs-,}${EMACS_SUFFIX}.1 \
268 + || die "moving emacs man page failed"
269 +
270 + # move info dir to avoid collisions with the dir file generated by portage
271 + mv "${ED}"/usr/share/info/${EMACS_SUFFIX}/dir{,.orig} \
272 + || die "moving info dir failed"
273 + touch "${ED}"/usr/share/info/${EMACS_SUFFIX}/.keepinfodir
274 + docompress -x /usr/share/info/${EMACS_SUFFIX}/dir.orig
275 +
276 + # avoid collision between slots, see bug #169033 e.g.
277 + rm "${ED}"/usr/share/emacs/site-lisp/subdirs.el
278 + rm -rf "${ED}"/usr/share/{appdata,applications,icons}
279 + rm -rf "${ED}"/var
280 +
281 + # remove unused <version>/site-lisp dir
282 + rm -rf "${ED}"/usr/share/emacs/${FULL_VERSION}/site-lisp
283 +
284 + # remove COPYING file (except for etc/COPYING used by describe-copying)
285 + rm "${ED}"/usr/share/emacs/${FULL_VERSION}/lisp/COPYING
286 +
287 + if use gzip-el; then
288 + # compress .el files when a corresponding .elc exists
289 + find "${ED}"/usr/share/emacs/${FULL_VERSION}/lisp -type f \
290 + -name "*.elc" -print | sed 's/\.elc$/.el/' | xargs gzip -9n
291 + assert "gzip .el failed"
292 + fi
293 +
294 + local cdir
295 + if use source; then
296 + cdir="/usr/share/emacs/${FULL_VERSION}/src"
297 + insinto "${cdir}"
298 + # This is not meant to install all the source -- just the
299 + # C source you might find via find-function
300 + doins src/*.{c,h,m}
301 + elif has installsources ${FEATURES}; then
302 + cdir="/usr/src/debug/${CATEGORY}/${PF}/${S#"${WORKDIR}/"}/src"
303 + fi
304 +
305 + sed -e "${cdir:+#}/^Y/d" -e "s/^[XY]//" >"${T}/${SITEFILE}" <<-EOF
306 + X
307 + ;;; ${PN}-${SLOT} site-lisp configuration
308 + X
309 + (when (string-match "\\\\\`${FULL_VERSION//./\\\\.}\\\\>" emacs-version)
310 + Y (setq find-function-C-source-directory
311 + Y "${EPREFIX}${cdir}")
312 + X (let ((path (getenv "INFOPATH"))
313 + X (dir "${EPREFIX}/usr/share/info/${EMACS_SUFFIX}")
314 + X (re "\\\\\`${EPREFIX}/usr/share/info\\\\>"))
315 + X (and path
316 + X ;; move Emacs Info dir before anything else in /usr/share/info
317 + X (let* ((p (cons nil (split-string path ":" t))) (q p))
318 + X (while (and (cdr q) (not (string-match re (cadr q))))
319 + X (setq q (cdr q)))
320 + X (setcdr q (cons dir (delete dir (cdr q))))
321 + X (setq Info-directory-list (prune-directory-list (cdr p)))))))
322 + EOF
323 + elisp-site-file-install "${T}/${SITEFILE}" || die
324 +
325 + dodoc README BUGS CONTRIBUTE
326 +
327 + if use aqua; then
328 + dodir /Applications/Gentoo
329 + rm -rf "${ED}"/Applications/Gentoo/Emacs${EMACS_SUFFIX#emacs}.app
330 + mv nextstep/Emacs.app \
331 + "${ED}"/Applications/Gentoo/Emacs${EMACS_SUFFIX#emacs}.app || die
332 + fi
333 +
334 + DOC_CONTENTS="You can set the version to be started by /usr/bin/emacs
335 + through the Emacs eselect module, which also redirects man and info
336 + pages. Therefore, several Emacs versions can be installed at the
337 + same time. \"man emacs.eselect\" for details.
338 + \\n\\nIf you upgrade from Emacs version 24.2 or earlier, then it is
339 + strongly recommended that you use app-admin/emacs-updater to rebuild
340 + all byte-compiled elisp files of the installed Emacs packages."
341 + use X && DOC_CONTENTS+="\\n\\nYou need to install some fonts for Emacs.
342 + Installing media-fonts/font-adobe-{75,100}dpi on the X server's
343 + machine would satisfy basic Emacs requirements under X11.
344 + See also https://wiki.gentoo.org/wiki/Xft_support_for_GNU_Emacs
345 + for how to enable anti-aliased fonts."
346 + use aqua && DOC_CONTENTS+="\\n\\nEmacs${EMACS_SUFFIX#emacs}.app is in
347 + \"${EPREFIX}/Applications/Gentoo\". You may want to copy or symlink
348 + it into /Applications by yourself."
349 + readme.gentoo_create_doc
350 +}
351 +
352 +pkg_preinst() {
353 + # move Info dir file to correct name
354 + local infodir=/usr/share/info/${EMACS_SUFFIX} f
355 + if [[ -f ${ED}${infodir}/dir.orig ]]; then
356 + mv "${ED}"${infodir}/dir{.orig,} || die "moving info dir failed"
357 + elif [[ -d "${ED}"${infodir} ]]; then
358 + # this should not happen in EAPI 4
359 + ewarn "Regenerating Info directory index in ${infodir} ..."
360 + rm -f "${ED}"${infodir}/dir{,.*}
361 + for f in "${ED}"${infodir}/*; do
362 + if [[ ${f##*/} != *-[0-9]* && -e ${f} ]]; then
363 + install-info --info-dir="${ED}"${infodir} "${f}" \
364 + || die "install-info failed"
365 + fi
366 + done
367 + fi
368 +}
369 +
370 +pkg_postinst() {
371 + elisp-site-regen
372 + readme.gentoo_print_elog
373 +
374 + if use livecd; then
375 + # force an update of the emacs symlink for the livecd/dvd,
376 + # because some microemacs packages set it with USE=livecd
377 + eselect emacs update
378 + elif [[ $(readlink "${EROOT}"/usr/bin/emacs) = ${EMACS_SUFFIX} ]]; then
379 + # refresh symlinks in case any installed files have changed
380 + eselect emacs set ${EMACS_SUFFIX}
381 + else
382 + eselect emacs update ifunset
383 + fi
384 +}
385 +
386 +pkg_postrm() {
387 + elisp-site-regen
388 + eselect emacs update ifunset
389 +}