summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBAUER Samuel (mazes_80) <samuel.bauer@yahoo.fr>2011-04-28 16:51:04 +0000
committerBAUER Samuel (mazes_80) <samuel.bauer@yahoo.fr>2011-04-28 16:51:04 +0000
commitea57c9e5d40e27ff0de3109b564e0aad605552a7 (patch)
tree58af36a70d770d528873c835a4cd42958e8cf949 /app-text
parentdev-util/eclipse-epic-bin: Comment out `inherit eclipse-ext', as package is m... (diff)
downloadsunrise-ea57c9e5d40e27ff0de3109b564e0aad605552a7.tar.gz
sunrise-ea57c9e5d40e27ff0de3109b564e0aad605552a7.tar.bz2
sunrise-ea57c9e5d40e27ff0de3109b564e0aad605552a7.zip
app-text/mathml-xml-dtd: mathml-xml-dtd-2.0.ebuild; #194501; revised ebuild; (mgorny, Tommy[D], binki, floppym)
svn path=/sunrise/; revision=11916
Diffstat (limited to 'app-text')
-rw-r--r--app-text/mathml-xml-dtd/ChangeLog5
-rw-r--r--app-text/mathml-xml-dtd/Manifest4
-rw-r--r--app-text/mathml-xml-dtd/mathml-xml-dtd-2.0.ebuild58
3 files changed, 37 insertions, 30 deletions
diff --git a/app-text/mathml-xml-dtd/ChangeLog b/app-text/mathml-xml-dtd/ChangeLog
index 82c02bd8c..3905eb5f9 100644
--- a/app-text/mathml-xml-dtd/ChangeLog
+++ b/app-text/mathml-xml-dtd/ChangeLog
@@ -2,6 +2,11 @@
# Copyright 1999-2011 Gentoo Foundation; Distributed under the GPL v2
# $Header: $
+ 28 Apr 2011; BAUER Samuel (mazes_80) <samuel.bauer@yahoo.fr>
+ mathml-xml-dtd-2.0.ebuild:
+ mathml-xml-dtd-2.0.ebuild; #194501; revised ebuild; (mgorny, Tommy[D],
+ binki, floppym)
+
24 Apr 2011; BAUER Samuel (mazes_80) <samuel.bauer@yahoo.fr>
+mathml-xml-dtd-2.0.ebuild, +metadata.xml:
app-text/mathml-xml-dtd-2.0 - #194501 - Regards to floppym, binki, and Tommy[D]
diff --git a/app-text/mathml-xml-dtd/Manifest b/app-text/mathml-xml-dtd/Manifest
index 943ee6143..998bddf9c 100644
--- a/app-text/mathml-xml-dtd/Manifest
+++ b/app-text/mathml-xml-dtd/Manifest
@@ -1,4 +1,4 @@
DIST mathml2.tgz 121304 RMD160 17341df158e62a55b90c2a1425ad779f25ee5017 SHA1 3cd9b1db626259756215e8aa92f70feff4c77116 SHA256 8b3e796574d63131fd3c90692c830ccf21a272433e3cc1b8c014979c84bd2ff4
-EBUILD mathml-xml-dtd-2.0.ebuild 2205 RMD160 ae9c144754bdc7db7195ac0c92f1e0f674af6f1f SHA1 8fe13b061380dd6fb71ea1d63884e23b33a47684 SHA256 81252fa0389db77ed21c3c84e38a12990016aa3379a1e28242362bb3bb578e54
-MISC ChangeLog 315 RMD160 be24aa3a02f499b001fdf4302bb2e75fc7aff7b4 SHA1 6bcefff86d867a14d30f8d21577eb78fb3fdf3eb SHA256 615c96c7ca297cb9cd9a2329b610ffb8c7f56ac73638f7ac793dd660bd1bce62
+EBUILD mathml-xml-dtd-2.0.ebuild 2098 RMD160 45f0e8fd6b85c6d8142733d272e111bc96ec13b2 SHA1 c31a6abf5987af8373d4675ff46834735caae9f2 SHA256 b704bfdd4f0b5365af75eda948c3e8375c306facfa522d40eddb7df9f2717740
+MISC ChangeLog 499 RMD160 7a304c761435708948ef459b4b68aed4fdf4249a SHA1 1b75d49be5421eb259ca6949eb7c9854b83d85b5 SHA256 defee09c5c2d40b05060caee5fa505a0f8c8cad5246ef014db124a5189d2423a
MISC metadata.xml 229 RMD160 f0f6417bec31ce8baba6d476664f7210c8c84c98 SHA1 e5f94f5caadc6f843fc90bb7959570cd503676fd SHA256 3b08fca3c878bdfc4e7639f477dd542d55a4ab5dce39a475e82633071d13eb3f
diff --git a/app-text/mathml-xml-dtd/mathml-xml-dtd-2.0.ebuild b/app-text/mathml-xml-dtd/mathml-xml-dtd-2.0.ebuild
index 5cdb6087d..7cebaac49 100644
--- a/app-text/mathml-xml-dtd/mathml-xml-dtd-2.0.ebuild
+++ b/app-text/mathml-xml-dtd/mathml-xml-dtd-2.0.ebuild
@@ -2,44 +2,37 @@
# Distributed under the terms of the GNU General Public License v2
# $Header: $
-inherit eutils versionator
+inherit versionator
+
+MY_P="${PN/-*/}$(get_major_version)"
DESCRIPTION="MathML DTD and entity files"
HOMEPAGE="http://www.w3.org/1998/Math/MathML"
-SRC_URI="http://www.w3.org/Math/DTD/${PN/-*/}$(get_major_version).tgz"
+SRC_URI="http://www.w3.org/Math/DTD/${MY_P}.tgz"
LICENSE="GPL-2"
SLOT="0"
-KEYWORDS="~x86"
+KEYWORDS="~amd64"
IUSE=""
-RDEPEND="dev-libs/libxml2"
-DEPEND="${RDEPEND}"
+DEPEND="dev-libs/libxml2"
+RDEPEND="${DEPEND}"
-S="${WORKDIR}/${PN/-*/}$(get_major_version)"
+S="${WORKDIR}/${MY_P}"
src_install() {
- install_directory="/usr/share/sgml/mathml/${P}"
+ INSTALL_DIRECTORY="/usr/share/sgml/mathml/${P}"
- insinto ${install_directory}
- doins * || die
+ insinto ${INSTALL_DIRECTORY}
+ doins -r * || die
}
pkg_postinst() {
- [ ! -e /etc/xml ] && mkdir -p /etc/xml/
-
- if [[ ! -r "${ROOT}"etc/xml/catalog ]] ; then
- ebegin "Creating root XML catalog"
- xmlcatalog --noout --create "${ROOT}"etc/xml/catalog
- eend $? "Failed creating root XML catalog"
- [ $? ] && return
- fi
-
- if [[ ! -r "${ROOT}"etc/xml/mathml ]] ; then
+ if [[ ! -r ${ROOT}etc/xml/mathml ]] ; then
ebegin "Creating MathML catalog"
xmlcatalog --noout --create "${ROOT}"etc/xml/mathml
- eend $? "Failed creating MathML catalog"
- [ $? ] && return
+ eend $? "Failed to create MathML catalog"
+ [[ $? -ne 0 ]] && return
fi
einfo "Updating Root XML Catalog"
@@ -50,15 +43,24 @@ pkg_postinst() {
"${ROOT}"etc/xml/catalog
einfo "Updating MathML Catalog"
- sed -n "/PUBLIC \"/ {N; s/\n/ /; s/SYSTEM//; s/\"[^\"]*$//; s/^[^\"]*\"//; s%\"[[:blank:]]\+\"%;file://${install_directory}/%; p};" ${S}/mathml2.dtd | while read entity
- do
- orig=`echo ${entity} | cut -f1 -d';'`
- replace=`echo ${entity} | cut -f2 -d';'`
- xmlcatalog --noout --add public "${orig}" "${replace}" "${ROOT}"etc/xml/mathml
- done
+
+ (
+ IFS=";"
+ sed -n "/PUBLIC \"/ {N; s/\n/ /; s/^[^\"]*\"//; s/SYSTEM//; s/\"[^\"]*$//; s%\"[[:blank:]]\+\"%;${INSTALL_DIRECTORY}/%; p};" \
+ "${ROOT}${INSTALL_DIRECTORY#/}"/mathml2.dtd | while read orig replace
+ do
+ xmlcatalog --noout --add public "${orig}" "file://${replace}" "${ROOT}"etc/xml/mathml
+ done
+ )
+
+ xmlcatalog --noout \
+ --add "rewriteSystem" \
+ "http://www.w3.org/TR/2001/REC-MathML2-20010221/dtd" "file://${INSTALL_DIRECTORY}" \
+ "${ROOT}"etc/xml/mathml
xmlcatalog --noout \
- --add "rewriteURI" "http://www.w3.org/TR/2001/REC-MathML2-20010221/dtd" "file://${install_directory}" \
+ --add "rewriteURI" \
+ "http://www.w3.org/TR/2001/REC-MathML2-20010221/dtd" "file://${INSTALL_DIRECTORY}" \
"${ROOT}"etc/xml/mathml
}