*/*: Drop stable ia64 keywords
[gentoo.git] / app-emacs / auctex / auctex-12.1-r1.ebuild
1 # Copyright 1999-2020 Gentoo Authors
2 # Distributed under the terms of the GNU General Public License v2
3
4 EAPI=7
5 NEED_EMACS=24
6
7 inherit elisp
8
9 DESCRIPTION="Extensible package for writing and formatting TeX files in Emacs"
10 HOMEPAGE="https://www.gnu.org/software/auctex/"
11 SRC_URI="mirror://gnu/${PN}/${P}.tar.gz"
12
13 LICENSE="GPL-3+ FDL-1.3+"
14 SLOT="0"
15 KEYWORDS="amd64 arm ppc ppc64 x86 ~amd64-linux ~x86-linux ~ppc-macos ~x86-macos ~sparc-solaris"
16 IUSE="preview-latex"
17
18 RDEPEND="virtual/latex-base
19         preview-latex? (
20                 app-text/dvipng
21                 app-text/ghostscript-gpl
22         )"
23 BDEPEND="${RDEPEND}"
24
25 ELISP_PATCHES="${P}-autoload.patch"
26 TEXMF="/usr/share/texmf-site"
27
28 src_configure() {
29         econf \
30                 --with-emacs \
31                 --with-auto-dir="${EPREFIX}/var/lib/auctex" \
32                 --with-lispdir="${EPREFIX}${SITELISP}/${PN}" \
33                 --with-packagelispdir="${EPREFIX}${SITELISP}/${PN}" \
34                 --with-packagedatadir="${EPREFIX}${SITEETC}/${PN}" \
35                 --with-texmf-dir="${EPREFIX}${TEXMF}" \
36                 --disable-build-dir-test \
37                 $(use_enable preview-latex preview)
38 }
39
40 src_compile() {
41         export VARTEXFONTS="${T}"/fonts
42         emake
43 }
44
45 src_install() {
46         emake -j1 DESTDIR="${D}" install
47         elisp-site-file-install "${FILESDIR}/50${PN}-gentoo.el"
48         if use preview-latex; then
49                 elisp-site-file-install "${FILESDIR}/60${PN}-gentoo.el"
50         fi
51         dodoc ChangeLog* CHANGES FAQ INSTALL PROBLEMS.preview README RELEASE TODO
52 }
53
54 pkg_postinst() {
55         use preview-latex && texmf-update
56         elisp-site-regen
57 }
58
59 pkg_postrm() {
60         use preview-latex && texmf-update
61         elisp-site-regen
62 }