1 |
commit: f411db0621fca6028431b8d98db02d3cb4444fa0 |
2 |
Author: Ulrich Müller <ulm <AT> gentoo <DOT> org> |
3 |
AuthorDate: Mon Feb 8 09:51:24 2021 +0000 |
4 |
Commit: Ulrich Müller <ulm <AT> gentoo <DOT> org> |
5 |
CommitDate: Mon Feb 8 09:52:04 2021 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=f411db06 |
7 |
|
8 |
app-editors/emacs: Keep Emacs 23 with GTK+ support for now |
9 |
|
10 |
Most likely slot 23 will be gone at the time GTK+ 2 leaves the tree. |
11 |
|
12 |
Bug: https://bugs.gentoo.org/769023 |
13 |
Package-Manager: Portage-3.0.14, Repoman-3.0.2 |
14 |
Signed-off-by: Ulrich Müller <ulm <AT> gentoo.org> |
15 |
|
16 |
app-editors/emacs/emacs-23.4-r21.ebuild | 345 -------------------------------- |
17 |
1 file changed, 345 deletions(-) |
18 |
|
19 |
diff --git a/app-editors/emacs/emacs-23.4-r21.ebuild b/app-editors/emacs/emacs-23.4-r21.ebuild |
20 |
deleted file mode 100644 |
21 |
index d9c732a605e..00000000000 |
22 |
--- a/app-editors/emacs/emacs-23.4-r21.ebuild |
23 |
+++ /dev/null |
24 |
@@ -1,345 +0,0 @@ |
25 |
-# Copyright 1999-2021 Gentoo Authors |
26 |
-# Distributed under the terms of the GNU General Public License v2 |
27 |
- |
28 |
-EAPI=7 |
29 |
-WANT_AUTOMAKE="none" |
30 |
- |
31 |
-inherit autotools elisp-common flag-o-matic readme.gentoo-r1 toolchain-funcs |
32 |
- |
33 |
-DESCRIPTION="The extensible, customizable, self-documenting real-time display editor" |
34 |
-HOMEPAGE="https://www.gnu.org/software/emacs/" |
35 |
-SRC_URI="mirror://gnu/emacs/${P}.tar.bz2 |
36 |
- https://dev.gentoo.org/~ulm/emacs/${P}-patches-23.tar.xz" |
37 |
- |
38 |
-LICENSE="GPL-3+ FDL-1.3+ BSD HPND MIT W3C unicode PSF-2" |
39 |
-SLOT="23" |
40 |
-KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~mips ~ppc ~ppc64 ~sparc ~x86 ~amd64-linux ~x86-linux ~ppc-macos" |
41 |
-IUSE="alsa aqua athena dbus games gconf gif gpm gui gzip-el jpeg kerberos livecd m17n-lib motif png sound source svg tiff toolkit-scroll-bars Xaw3d xft +xpm" |
42 |
- |
43 |
-RDEPEND="acct-group/mail |
44 |
- app-emacs/emacs-common-gentoo[games?,gui(-)?] |
45 |
- net-libs/liblockfile |
46 |
- sys-libs/ncurses:0= |
47 |
- kerberos? ( virtual/krb5 ) |
48 |
- alsa? ( media-libs/alsa-lib ) |
49 |
- games? ( acct-group/gamestat ) |
50 |
- gpm? ( sys-libs/gpm ) |
51 |
- dbus? ( sys-apps/dbus ) |
52 |
- gui? ( !aqua? ( |
53 |
- x11-libs/libICE |
54 |
- x11-libs/libSM |
55 |
- x11-libs/libX11 |
56 |
- x11-misc/xbitmaps |
57 |
- gconf? ( >=gnome-base/gconf-2.26.2 ) |
58 |
- gif? ( media-libs/giflib:0= ) |
59 |
- jpeg? ( virtual/jpeg:0= ) |
60 |
- png? ( >=media-libs/libpng-1.4:0= ) |
61 |
- svg? ( >=gnome-base/librsvg-2.0 ) |
62 |
- tiff? ( media-libs/tiff:0 ) |
63 |
- xpm? ( x11-libs/libXpm ) |
64 |
- xft? ( |
65 |
- media-libs/fontconfig |
66 |
- media-libs/freetype |
67 |
- x11-libs/libXft |
68 |
- x11-libs/libXrender |
69 |
- m17n-lib? ( |
70 |
- >=dev-libs/libotf-0.9.4 |
71 |
- >=dev-libs/m17n-lib-1.5.1 |
72 |
- ) |
73 |
- ) |
74 |
- motif? ( |
75 |
- >=x11-libs/motif-2.3:0 |
76 |
- x11-libs/libXpm |
77 |
- x11-libs/libXext |
78 |
- x11-libs/libXmu |
79 |
- x11-libs/libXt |
80 |
- ) |
81 |
- !motif? ( |
82 |
- Xaw3d? ( |
83 |
- x11-libs/libXaw3d |
84 |
- x11-libs/libXext |
85 |
- x11-libs/libXmu |
86 |
- x11-libs/libXt |
87 |
- ) |
88 |
- !Xaw3d? ( athena? ( |
89 |
- x11-libs/libXaw |
90 |
- x11-libs/libXext |
91 |
- x11-libs/libXmu |
92 |
- x11-libs/libXt |
93 |
- ) ) |
94 |
- ) |
95 |
- ) )" |
96 |
- |
97 |
-DEPEND="${RDEPEND} |
98 |
- gui? ( !aqua? ( x11-base/xorg-proto ) )" |
99 |
- |
100 |
-BDEPEND="app-eselect/eselect-emacs |
101 |
- virtual/pkgconfig |
102 |
- gzip-el? ( app-arch/gzip )" |
103 |
- |
104 |
-RDEPEND="${RDEPEND} |
105 |
- app-eselect/eselect-emacs" |
106 |
- |
107 |
-EMACS_SUFFIX="emacs-${SLOT}" |
108 |
-SITEFILE="20${EMACS_SUFFIX}-gentoo.el" |
109 |
-# FULL_VERSION keeps the full version number, which is needed in |
110 |
-# order to determine some path information correctly for copy/move |
111 |
-# operations later on |
112 |
-FULL_VERSION="${PV%%_*}" |
113 |
-S="${WORKDIR}/emacs-${FULL_VERSION}" |
114 |
- |
115 |
-src_prepare() { |
116 |
- eapply ../patch |
117 |
- eapply_user |
118 |
- |
119 |
- sed -i -e "/^\\.so/s/etags/&-${EMACS_SUFFIX}/" doc/man/ctags.1 \ |
120 |
- || die "unable to sed ctags.1" |
121 |
- |
122 |
- if ! use alsa; then |
123 |
- # ALSA is detected even if not requested by its USE flag. |
124 |
- # Suppress it by supplying pkg-config with a wrong library name. |
125 |
- sed -i -e "/ALSA_MODULES=/s/alsa/DiSaBlEaLsA/" configure.in \ |
126 |
- || die "unable to sed configure.in" |
127 |
- fi |
128 |
- if ! use gzip-el; then |
129 |
- # Emacs' build system automatically detects the gzip binary and |
130 |
- # compresses el files. We don't want that so confuse it with a |
131 |
- # wrong binary name |
132 |
- sed -i -e "s/ gzip/ PrEvEnTcOmPrEsSiOn/" configure.in \ |
133 |
- || die "unable to sed configure.in" |
134 |
- fi |
135 |
- |
136 |
- mv configure.in configure.ac || die |
137 |
- eautoreconf |
138 |
- touch src/stamp-h.in || die |
139 |
-} |
140 |
- |
141 |
-src_configure() { |
142 |
- strip-flags |
143 |
- filter-flags -fstrict-aliasing -pie |
144 |
- append-flags $(test-flags -fno-strict-aliasing) |
145 |
- append-ldflags $(test-flags -no-pie) #639568 |
146 |
- |
147 |
- if use ia64; then |
148 |
- replace-flags "-O[2-9]" -O1 #325373 |
149 |
- else |
150 |
- replace-flags "-O[3-9]" -O2 |
151 |
- fi |
152 |
- |
153 |
- # Don't trigger a floating point exception for NaNs on alpha |
154 |
- use alpha && append-flags -mieee |
155 |
- |
156 |
- local myconf |
157 |
- |
158 |
- if use alsa && ! use sound; then |
159 |
- einfo "Although sound USE flag is disabled you chose to have alsa," |
160 |
- einfo "so sound is switched on anyway." |
161 |
- myconf+=" --with-sound" |
162 |
- else |
163 |
- myconf+=" $(use_with sound)" |
164 |
- fi |
165 |
- |
166 |
- if ! use gui; then |
167 |
- einfo "Configuring to build without window system support" |
168 |
- myconf+=" --without-x --without-ns" |
169 |
- elif use aqua; then |
170 |
- einfo "Configuring to build with Nextstep (Macintosh Cocoa) support" |
171 |
- myconf+=" --with-ns --disable-ns-self-contained" |
172 |
- myconf+=" --without-x" |
173 |
- else |
174 |
- myconf+=" --with-x --without-ns" |
175 |
- myconf+=" $(use_with gconf)" |
176 |
- myconf+=" $(use_with toolkit-scroll-bars)" |
177 |
- myconf+=" $(use_with gif)" |
178 |
- myconf+=" $(use_with jpeg)" |
179 |
- myconf+=" $(use_with png)" |
180 |
- myconf+=" $(use_with svg rsvg)" |
181 |
- myconf+=" $(use_with tiff)" |
182 |
- myconf+=" $(use_with xpm)" |
183 |
- |
184 |
- if use xft; then |
185 |
- myconf+=" --with-xft" |
186 |
- myconf+=" $(use_with m17n-lib libotf)" |
187 |
- myconf+=" $(use_with m17n-lib m17n-flt)" |
188 |
- else |
189 |
- myconf+=" --without-xft" |
190 |
- myconf+=" --without-libotf --without-m17n-flt" |
191 |
- use m17n-lib && ewarn \ |
192 |
- "USE flag \"m17n-lib\" has no effect if \"xft\" is not set." |
193 |
- fi |
194 |
- |
195 |
- local f |
196 |
- if use motif; then |
197 |
- einfo "Configuring to build with Motif toolkit" |
198 |
- myconf+=" --with-x-toolkit=motif" |
199 |
- for f in Xaw3d athena; do |
200 |
- use ${f} && ewarn \ |
201 |
- "USE flag \"${f}\" has no effect if \"motif\" is set." |
202 |
- done |
203 |
- elif use athena || use Xaw3d; then |
204 |
- einfo "Configuring to build with Athena/Lucid toolkit" |
205 |
- myconf+=" --with-x-toolkit=lucid $(use_with Xaw3d xaw3d)" |
206 |
- else |
207 |
- einfo "Configuring to build with no toolkit" |
208 |
- myconf+=" --with-x-toolkit=no" |
209 |
- fi |
210 |
- fi |
211 |
- |
212 |
- # According to configure, this option is only used for GNU/Linux |
213 |
- # (x86_64 and s390). For Gentoo Prefix we have to explicitly spell |
214 |
- # out the location because $(get_libdir) does not necessarily return |
215 |
- # something that matches the host OS's libdir naming (e.g. RHEL). |
216 |
- local crtdir=$($(tc-getCC) -print-file-name=crt1.o) |
217 |
- crtdir=${crtdir%/*} |
218 |
- |
219 |
- econf \ |
220 |
- --program-suffix="-${EMACS_SUFFIX}" \ |
221 |
- --infodir="${EPREFIX}"/usr/share/info/${EMACS_SUFFIX} \ |
222 |
- --localstatedir="${EPREFIX}"/var \ |
223 |
- --enable-locallisppath="${EPREFIX}/etc/emacs:${EPREFIX}${SITELISP}" \ |
224 |
- --with-crt-dir="${crtdir}" \ |
225 |
- --with-gameuser=":gamestat" \ |
226 |
- --without-hesiod \ |
227 |
- $(use_with kerberos) $(use_with kerberos kerberos5) \ |
228 |
- $(use_with gpm) \ |
229 |
- $(use_with dbus) \ |
230 |
- ${myconf} |
231 |
-} |
232 |
- |
233 |
-src_compile() { |
234 |
- # Disable sandbox when dumping. For the unbelievers, see bug #131505 |
235 |
- emake CC="$(tc-getCC)" \ |
236 |
- AR="$(tc-getAR) cq" \ |
237 |
- RANLIB="$(tc-getRANLIB)" \ |
238 |
- RUN_TEMACS="SANDBOX_ON=0 LD_PRELOAD= env ./temacs" |
239 |
-} |
240 |
- |
241 |
-src_install() { |
242 |
- emake DESTDIR="${D}" install |
243 |
- |
244 |
- rm "${ED}"/usr/bin/emacs-${FULL_VERSION}-${EMACS_SUFFIX} \ |
245 |
- || die "removing duplicate emacs executable failed" |
246 |
- mv "${ED}"/usr/bin/emacs-${EMACS_SUFFIX} "${ED}"/usr/bin/${EMACS_SUFFIX} \ |
247 |
- || die "moving emacs executable failed" |
248 |
- |
249 |
- # move man pages to the correct place |
250 |
- local m |
251 |
- mv "${ED}"/usr/share/man/man1/{emacs,${EMACS_SUFFIX}}.1 \ |
252 |
- || die "moving emacs man page failed" |
253 |
- for m in b2m ctags ebrowse emacsclient etags grep-changelog rcs-checkin; do |
254 |
- mv "${ED}"/usr/share/man/man1/${m}{,-${EMACS_SUFFIX}}.1 \ |
255 |
- || die "moving ${m} man page failed" |
256 |
- done |
257 |
- |
258 |
- # move info dir to avoid collisions with the dir file generated by portage |
259 |
- mv "${ED}"/usr/share/info/${EMACS_SUFFIX}/dir{,.orig} \ |
260 |
- || die "moving info dir failed" |
261 |
- touch "${ED}"/usr/share/info/${EMACS_SUFFIX}/.keepinfodir |
262 |
- docompress -x /usr/share/info/${EMACS_SUFFIX}/dir.orig |
263 |
- |
264 |
- # movemail must be setgid mail |
265 |
- fowners root:mail /usr/libexec/emacs/${FULL_VERSION}/${CHOST}/movemail |
266 |
- fperms 2751 /usr/libexec/emacs/${FULL_VERSION}/${CHOST}/movemail |
267 |
- |
268 |
- # avoid collision between slots, see bug #169033 e.g. |
269 |
- rm "${ED}"/usr/share/emacs/site-lisp/subdirs.el |
270 |
- rm -rf "${ED}"/usr/share/{applications,icons} |
271 |
- rm -rf "${ED}"/var |
272 |
- |
273 |
- # remove unused <version>/site-lisp dir |
274 |
- rm -rf "${ED}"/usr/share/emacs/${FULL_VERSION}/site-lisp |
275 |
- |
276 |
- # remove COPYING file (except for etc/COPYING used by describe-copying) |
277 |
- rm "${ED}"/usr/share/emacs/${FULL_VERSION}/lisp/COPYING |
278 |
- |
279 |
- local cdir |
280 |
- if use source; then |
281 |
- cdir="/usr/share/emacs/${FULL_VERSION}/src" |
282 |
- insinto "${cdir}" |
283 |
- # This is not meant to install all the source -- just the |
284 |
- # C source you might find via find-function |
285 |
- doins src/*.{c,h,m} |
286 |
- doins -r src/{m,s} |
287 |
- rm "${ED}"/usr/share/emacs/${FULL_VERSION}/src/Makefile.c |
288 |
- rm "${ED}"/usr/share/emacs/${FULL_VERSION}/src/{m,s}/README |
289 |
- elif has installsources ${FEATURES}; then |
290 |
- cdir="/usr/src/debug/${CATEGORY}/${PF}/${S#"${WORKDIR}/"}/src" |
291 |
- fi |
292 |
- |
293 |
- sed -e "${cdir:+#}/^Y/d" -e "s/^[XY]//" >"${T}/${SITEFILE}" <<-EOF || die |
294 |
- X |
295 |
- ;;; ${EMACS_SUFFIX} site-lisp configuration |
296 |
- X |
297 |
- (when (string-match "\\\\\`${FULL_VERSION//./\\\\.}\\\\>" emacs-version) |
298 |
- Y (setq find-function-C-source-directory |
299 |
- Y "${EPREFIX}${cdir}") |
300 |
- X (let ((path (getenv "INFOPATH")) |
301 |
- X (dir "${EPREFIX}/usr/share/info/${EMACS_SUFFIX}") |
302 |
- X (re "\\\\\`${EPREFIX}/usr/share\\\\>")) |
303 |
- X (and path |
304 |
- X ;; move Emacs Info dir before anything else in /usr/share |
305 |
- X (let* ((p (cons nil (split-string path ":" t))) (q p)) |
306 |
- X (while (and (cdr q) (not (string-match re (cadr q)))) |
307 |
- X (setq q (cdr q))) |
308 |
- X (setcdr q (cons dir (delete dir (cdr q)))) |
309 |
- X (setq Info-directory-list (prune-directory-list (cdr p))))))) |
310 |
- EOF |
311 |
- elisp-site-file-install "${T}/${SITEFILE}" || die |
312 |
- |
313 |
- dodoc README BUGS |
314 |
- |
315 |
- if use gui && use aqua; then |
316 |
- dodir /Applications/Gentoo |
317 |
- rm -rf "${ED}"/Applications/Gentoo/${EMACS_SUFFIX^}.app |
318 |
- mv nextstep/Emacs.app \ |
319 |
- "${ED}"/Applications/Gentoo/${EMACS_SUFFIX^}.app || die |
320 |
- fi |
321 |
- |
322 |
- local DOC_CONTENTS="You can set the version to be started by |
323 |
- /usr/bin/emacs through the Emacs eselect module, which also |
324 |
- redirects man and info pages. Therefore, several Emacs versions can |
325 |
- be installed at the same time. \"man emacs.eselect\" for details. |
326 |
- \\n\\nIf you upgrade from a previous major version of Emacs, then |
327 |
- it is strongly recommended that you use app-admin/emacs-updater |
328 |
- to rebuild all byte-compiled elisp files of the installed Emacs |
329 |
- packages." |
330 |
- if use gui; then |
331 |
- DOC_CONTENTS+="\\n\\nYou need to install some fonts for Emacs. |
332 |
- Installing media-fonts/font-adobe-{75,100}dpi on the X server's |
333 |
- machine would satisfy basic Emacs requirements under X11. |
334 |
- See also https://wiki.gentoo.org/wiki/Xft_support_for_GNU_Emacs |
335 |
- for how to enable anti-aliased fonts." |
336 |
- use aqua && DOC_CONTENTS+="\\n\\n${EMACS_SUFFIX^}.app is in |
337 |
- \"${EPREFIX}/Applications/Gentoo\". You may want to copy or |
338 |
- symlink it into /Applications by yourself." |
339 |
- fi |
340 |
- readme.gentoo_create_doc |
341 |
-} |
342 |
- |
343 |
-pkg_preinst() { |
344 |
- # move Info dir file to correct name |
345 |
- if [[ -d ${ED}/usr/share/info ]]; then |
346 |
- mv "${ED}"/usr/share/info/${EMACS_SUFFIX}/dir{.orig,} || die |
347 |
- fi |
348 |
-} |
349 |
- |
350 |
-pkg_postinst() { |
351 |
- elisp-site-regen |
352 |
- readme.gentoo_print_elog |
353 |
- |
354 |
- if use livecd; then |
355 |
- # force an update of the emacs symlink for the livecd/dvd, |
356 |
- # because some microemacs packages set it with USE=livecd |
357 |
- eselect emacs update |
358 |
- elif [[ $(readlink "${EROOT}"/usr/bin/emacs) = ${EMACS_SUFFIX} ]]; then |
359 |
- # refresh symlinks in case any installed files have changed |
360 |
- eselect emacs set ${EMACS_SUFFIX} |
361 |
- else |
362 |
- eselect emacs update ifunset |
363 |
- fi |
364 |
-} |
365 |
- |
366 |
-pkg_postrm() { |
367 |
- elisp-site-regen |
368 |
- eselect emacs update ifunset |
369 |
-} |