Changeset 4abc9ec
- Timestamp:
- 09/17/2006 10:26:55 AM (18 years ago)
- Branches:
- experimental
- Children:
- 2020b1b
- Parents:
- 6ef1f44
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
blfs-tool
r6ef1f44 r4abc9ec 73 73 [[ $VERBOSITY > 0 ]] && echo "OK" 74 74 75 [[ $VERBOSITY > 0 ]] && echo -n "Loading function <func_check_version.sh>..." 76 source $COMMON_DIR/func_check_version.sh 77 [[ $? > 0 ]] && echo " function module did not load.." && exit 2 78 [[ $VERBOSITY > 0 ]] && echo "OK" 79 75 80 [[ $VERBOSITY > 0 ]] && echo -n "Loading function <func_validate_configs.sh>..." 76 81 source $COMMON_DIR/func_validate_configs.sh … … 94 99 * ) TREE=tags/${BRANCH_ID}/BOOK ;; 95 100 esac 101 102 # Check for minimun dependencies versions 103 xsltprocVer=`xsltproc -V | head -n1 ` 104 libxmlVer=$(echo $xsltprocVer | cut -d " " -f3) 105 libxsltVer=$(echo $xsltprocVer | cut -d " " -f5) 106 tidyVer=`tidy -V | cut -d " " -f9` 107 108 # Version numbers are packed strings not xx.yy.zz format. 109 check_version "2.06.20" "${libxmlVer:0:1}.${libxmlVer:1:2}.${libxmlVer:3:2}" "LIBXML2" 110 check_version "1.01.14" "${libxsltVer:0:1}.${libxsltVer:1:2}.${libxsltVer:3:2}" "LIBXSLT" 111 check_version "2004" "${tidyVer}" "TIDY" 112 113 XML_FILE="<?xml version='1.0' encoding='ISO-8859-1'?> 114 <?xml-stylesheet type='text/xsl' href='http://docbook.sourceforge.net/release/xsl/1.69.1/xhtml/docbook.xsl'?> 115 <!DOCTYPE article PUBLIC '-//OASIS//DTD DocBook XML V4.4//EN' 116 'http://www.oasis-open.org/docbook/xml/4.4/docbookx.dtd'> 117 <article> 118 <title>Test file</title> 119 <sect1> 120 <title>Some title</title> 121 <para>Some text</para> 122 </sect1> 123 </article>" 124 125 if `echo $XML_FILE | xmllint -noout -postvalid - 2>/dev/null` ; then 126 check_version "4.4" "4.4" "DocBook XML DTD" 127 else 128 echo "Warning: not found a working DocBook XML DTD 4.4 installation" 129 exit 2 130 fi 131 132 if `echo $XML_FILE | xsltproc --noout - 2>/dev/null` ; then 133 check_version "1.69.1" "1.69.1" "DocBook XSL" 134 else 135 echo "Warning: not found a working DocBook XSL 1.69.1 installation" 136 exit 2 137 fi 138 139 echo "${SD_BORDER}${nl_}" 96 140 97 141 # For consistency with other books -
jhalfs
r6ef1f44 r4abc9ec 250 250 check_version "1.15.0" "${tarVer}" "TAR" 251 251 252 # Check for minimum sudo version 252 253 SUDO_LOC="`whereis -b sudo | cut -d " " -f2`" 253 254 if [ -x $SUDO_LOC ]; then … … 259 260 fi 260 261 262 # Check for minimum libxml2 and libxslt versions 261 263 xsltprocVer=`xsltproc -V | head -n1 ` 262 264 libxmlVer=$(echo $xsltprocVer | cut -d " " -f3) 263 265 libxsltVer=$(echo $xsltprocVer | cut -d " " -f5) 264 tidyVer=`tidy -V | cut -d " " -f9` 265 266 # Version numbers are packed strings not xx.yy.zz format. 266 267 # Version numbers are packed strings not xx.yy.zz format. 267 268 check_version "2.06.20" "${libxmlVer:0:1}.${libxmlVer:1:2}.${libxmlVer:3:2}" "LIBXML2" 268 269 check_version "1.01.14" "${libxsltVer:0:1}.${libxsltVer:1:2}.${libxsltVer:3:2}" "LIBXSLT" 269 check_version "2004" "${tidyVer}" "TIDY" 270 271 # The next versions checks are required only when BLFS_TOOL is set and 272 # this dependencies has not be selected for installation 273 if [[ "$BLFS_TOOL" = "y" ]] ; then 274 275 if [[ -z "$DEP_TIDY" ]] ; then 276 tidyVer=`tidy -V | cut -d " " -f9` 277 check_version "2004" "${tidyVer}" "TIDY" 278 fi 279 280 # Check if the proper DocBook-XML-DTD and DocBook-XSL are correctly installed 281 XML_FILE="<?xml version='1.0' encoding='ISO-8859-1'?> 282 <?xml-stylesheet type='text/xsl' href='http://docbook.sourceforge.net/release/xsl/1.69.1/xhtml/docbook.xsl'?> 283 <!DOCTYPE article PUBLIC '-//OASIS//DTD DocBook XML V4.4//EN' 284 'http://www.oasis-open.org/docbook/xml/4.4/docbookx.dtd'> 285 <article> 286 <title>Test file</title> 287 <sect1> 288 <title>Some title</title> 289 <para>Some text</para> 290 </sect1> 291 </article>" 292 293 if [[ -z "$DEP_DBXML" ]] ; then 294 if `echo $XML_FILE | xmllint -noout -postvalid - 2>/dev/null` ; then 295 check_version "4.4" "4.4" "DocBook XML DTD" 296 else 297 echo "Warning: not found a working DocBook XML DTD 4.4 installation" 298 exit 2 299 fi 300 fi 301 302 if [[ -z "$DEP_DBXSL" ]] ; then 303 if `echo $XML_FILE | xsltproc --noout - 2>/dev/null` ; then 304 check_version "1.69.1" "1.69.1" "DocBook XSL" 305 else 306 echo "Warning: not found a working DocBook XSL 1.69.1 installation" 307 exit 2 308 fi 309 fi 310 311 fi 270 312 271 313 echo "${SD_BORDER}${nl_}"
Note:
See TracChangeset
for help on using the changeset viewer.