Mercurial > mplayer.hg
comparison DOCS/xml/configure @ 11817:19919e913e3d
Shiny new build system by Torinthiel, polished and improved by myself.
author | diego |
---|---|
date | Tue, 20 Jan 2004 23:27:25 +0000 |
parents | bb3e24e796eb |
children | 43f35b915dc7 |
comparison
equal
deleted
inserted
replaced
11816:637af9175b65 | 11817:19919e913e3d |
---|---|
4 # the other stuff necessary to convert the XML documentation. | 4 # the other stuff necessary to convert the XML documentation. |
5 | 5 |
6 _xsltwrapper="xsltproc.sh" | 6 _xsltwrapper="xsltproc.sh" |
7 _xmllintwrapper="xmllint.sh" | 7 _xmllintwrapper="xmllint.sh" |
8 | 8 |
9 echo "Searching for XML catalogs..." | |
9 for _try_catalog in /etc/sgml/catalog /usr/share/sgml/docbook/xml-dtd-4.1.2/xmlcatalog /usr/share/apps/ksgmltools2/customization/en/catalog /usr/share/sgml/catalog /usr/local/share/sgml/catalog /usr/lib/sgml/catalog /usr/local/lib/sgml/catalog /usr/share/docbook-xml42/catalog.xml /usr/share/sgml/docbook/xmlcatalog | 10 for _try_catalog in /etc/sgml/catalog /usr/share/sgml/docbook/xml-dtd-4.1.2/xmlcatalog /usr/share/apps/ksgmltools2/customization/en/catalog /usr/share/sgml/catalog /usr/local/share/sgml/catalog /usr/lib/sgml/catalog /usr/local/lib/sgml/catalog /usr/share/docbook-xml42/catalog.xml /usr/share/sgml/docbook/xmlcatalog |
10 do | 11 do |
11 if test -f "$_try_catalog" | 12 if test -f "$_try_catalog" |
12 then | 13 then |
13 _catalog=$_try_catalog | 14 _catalog=$_try_catalog |
91 <xsl:include href="html-common.xsl"/> | 92 <xsl:include href="html-common.xsl"/> |
92 | 93 |
93 </xsl:stylesheet> | 94 </xsl:stylesheet> |
94 EOF | 95 EOF |
95 | 96 |
96 | 97 echo "Searching for DTD..." |
98 for _try_dtd in /usr/share/sgml/docbook/dtd/xml/4.1.2/docbookx.dtd /usr/share/docbook-xml42/docbookx.dtd /usr/share/sgml/docbook/xml-dtd-4.1.2/docbookx.dtd | |
99 do | |
100 if test -f "$_try_dtd" | |
101 then | |
102 _dtd=$_try_dtd | |
103 break | |
104 fi | |
105 done | |
106 | |
107 if test -z "$_dtd" | |
108 then | |
109 _dtd=/usr/share/sgml/docbook/dtd/xml/4.1.2/docbookx.dtd | |
110 echo "Not found. Using default ($_dtd)." | |
111 else | |
112 echo "Found docbookx.dtd at $_dtd" | |
113 fi | |
114 | |
115 for lang in `grep 'SUBDIRS =' Makefile|cut -d= -f2`; do | |
116 cat > $lang/main.xml << EOF | |
117 <?xml version="1.0" encoding="iso-8859-1" standalone="no"?> | |
118 <!DOCTYPE book PUBLIC "-//OASIS//DTD DocBook XML V4.1.2//EN" | |
119 "$_dtd" | |
120 [ | |
121 EOF | |
122 | |
123 for file in `find $lang en -name \*.xml -exec basename \{\} \; | uniq`; do | |
124 echo '<!ENTITY '$file' SYSTEM "'$file'">' >> $lang/main.xml | |
125 done | |
126 | |
127 cat >> $lang/main.xml << EOF | |
128 ]> | |
129 <book id="index" lang="$lang"> | |
130 &documentation.xml; | |
131 </book> | |
132 EOF | |
133 | |
134 done | |
97 | 135 |
98 echo "Looking for a valid XSLT processor..." | 136 echo "Looking for a valid XSLT processor..." |
99 # Checks for xsltproc, then checks for the Saxon processor (it needs Java). | 137 # Checks for xsltproc, then checks for the Saxon processor (it needs Java). |
100 # Also checks for Jade/OpenJade. | 138 # Also checks for Jade/OpenJade. |
101 #FIXME: Add support for the xalan/xalan2 XSLT processors. | 139 #FIXME: Add support for the xalan/xalan2 XSLT processors. |
248 echo "Searching for XML checker..." | 286 echo "Searching for XML checker..." |
249 for _try_xmllint in xmllint | 287 for _try_xmllint in xmllint |
250 do | 288 do |
251 if command -v $_try_xmllint > /dev/null 2>&1 | 289 if command -v $_try_xmllint > /dev/null 2>&1 |
252 then | 290 then |
253 echo "Found: $_try_xmllint" | 291 echo "Found $_try_xmllint" |
254 if test -n "$_catalog" | 292 if test -n "$_catalog" |
255 then | 293 then |
256 _xmllint_command="$_try_xmllint --noout --noent --postvalid --catalogs \$*" | 294 _xmllint_command="$_try_xmllint --noout --noent --postvalid --catalogs \$*" |
257 else | 295 else |
258 _xmllint_command="$_try_xmllint --noout --noent --postvalid \$*" | 296 _xmllint_command="$_try_xmllint --noout --noent --postvalid \$*" |