blob: dff9692bed61ff29efd318fcd8b1fd0a43463320 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
|
# Copyright 1999-2008 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Header: /var/cvsroot/gentoo-x86/app-emacs/nxml-svg-schemas/nxml-svg-schemas-1.1.20081123.ebuild,v 1.2 2008/11/26 10:02:11 armin76 Exp $
inherit elisp
DESCRIPTION="Extension for nxml-mode with SVG 1.1 schemas"
HOMEPAGE="http://www.w3.org/TR/SVG11/"
# original SRC_URI is http://www.w3.org/Graphics/SVG/1.1/rng/rng.zip
# but since it's unversioned, I versioned it and got it locally.
SRC_URI="http://www.flameeyes.eu/gentoo-distfiles/w3c-svg-rng-${PV}.zip"
# This is truly as-is!
LICENSE="as-is"
# In a future we might have 1.2 schemas too, but for now we can only
# install this one anyway because the schemas.xml syntax is not
# sophisticated enough.
SLOT="1.1"
KEYWORDS="~amd64 ~x86"
IUSE=""
RDEPEND="|| ( >=app-emacs/nxml-mode-20041004-r3 >=virtual/emacs-23 )"
# Yes this requires Java, but I'd rather not repackage this, if you
# know something better in C, I'll be glad to use that.
DEPEND="app-text/trang"
SITEFILE=60${PN}-gentoo.el
S="${WORKDIR}"
src_unpack() {
unpack ${A}
# we don't need the doctype for our work
sed -i -e '/DOCTYPE grammar/d' *.rng || die "sed failed"
}
src_compile() {
emake -f "${FILESDIR}/Makefile-trang" || die "trang failed"
}
src_install() {
insinto ${SITEETC}/${PN}
doins "${FILESDIR}/schemas.xml" *.rnc || die "install failed"
elisp-site-file-install "${FILESDIR}/${SITEFILE}" || die
}
pkg_postinst () {
elisp-site-regen
if [ $(emacs -batch -q --eval "(princ (fboundp 'nxml-mode))") = nil ]; then
ewarn "This package needs nxml-mode. You should either install"
ewarn "app-emacs/nxml-mode, or use \"eselect emacs\" to select"
ewarn "an Emacs version >= 23."
fi
}
|