Ignore:
Timestamp:
09/19/2007 04:50:48 PM (17 years ago)
Author:
Manuel Canales Esparcia <manuel@…>
Branches:
experimental
Children:
3778352
Parents:
0510381
Message:

Updated experimental branch to current trunk code.

File:
1 moved

Legend:

Unmodified
Added
Removed
  • common/libs/func_check_version.sh

    r0510381 r9c9775f  
    3535     echo -e "\n\t\t$TXT version -->${tst_version}<-- is too old.
    3636                    This script requires ${ref_version} or greater\n"
    37      exit 1
     37   # Ask the user instead of bomb, to make happy that packages which version
     38   # ouput don't follow our expectations
     39    echo "If you are sure that you have instaled a proper version of ${BOLD}$TXT${OFF}"
     40    echo "but jhalfs has failed to detect it, press 'c' and 'ENTER' keys to continue,"
     41    echo -n "otherwise press 'ENTER' key to stop jhalfs.  "
     42    read ANSWER
     43    if [ x$ANSWER != "xc" ] ; then
     44      echo "${nl_}Please, install a proper $TXT version.${nl_}"
     45      exit 1
     46    else
     47      minor=$ref_minor
     48      revision=$ref_revision
     49    fi
    3850  }
    3951
     
    4153
    4254#  echo -ne "$TXT:\t${L_arrow}${BOLD}${tst_version}${OFF}${R_arrow}"
    43   IFS=".-(p"   # Split up w.x.y.z as well as w.x.y-rc  (catch release candidates)
     55  IFS=".-(pa"   # Split up w.x.y.z as well as w.x.y-rc  (catch release candidates)
    4456  set -- $ref_version # set postional parameters to minimum ver values
    4557  ref_major=$1; ref_minor=$2; ref_revision=$3
     
    6779
    6880  # LFS/HLFS/CLFS prerequisites
    69   if [ ! "${PROGNAME}" = "hlfs" ]; then
    70     check_version "2.6.2"    "`uname -r`"                                     "KERNEL"
    71     check_version "2.0.5"    "$BASH_VERSION"                                  "BASH"
    72     check_version "3.0.0"    "`gcc -dumpversion`"                             "GCC"
    73     libcVer="`/lib/libc.so.6 | head -n1`"
    74     libcVer="${libcVer##*version }"
    75     check_version "2.2.5"    ${libcVer%%,*}                                     "GLIBC"
    76     check_version "2.12"     "$(ld --version  | head -n1 | cut -d" " -f4)"      "BINUTILS"
    77     check_version "1.14"     "$(tar --version | head -n1 | cut -d" " -f4)"      "TAR"
    78     bzip2Ver="$(bzip2 --version 2>&1 < /dev/null | head -n1 | cut -d" " -f8)"
    79     check_version "1.0.2"    "${bzip2Ver%%,*}"                                   "BZIP2"
    80     check_version "5.0"      "$(chown --version | head -n1 | cut -d")" -f2)"     "COREUTILS"
    81     check_version "2.8"      "$(diff --version  | head -n1 | cut -d" " -f4)"     "DIFF"
    82     check_version "4.1.20"   "$(find --version  | head -n1 | cut -d" " -f4)"     "FIND"
    83     check_version "3.0"      "$(gawk --version  | head -n1 | cut -d" " -f3)"     "GAWK"
    84     check_version "2.5"      "$(grep --version  | head -n1 | cut -d" " -f4)"     "GREP"
    85     check_version "1.2.4"    "$(gzip --version 2>&1 | head -n1 | cut -d" " -f2)" "GZIP"
    86     check_version "3.79.1"   "$(make --version  | head -n1 | cut -d " " -f3 | cut -c1-4)"    "MAKE"
    87     check_version "2.5.4"    "$(patch --version | head -n1 | cut -d" " -f2)"     "PATCH"
    88     check_version "3.0.2"    "$(sed --version   | head -n1 | cut -d" " -f4)"     "SED"
    89   else
    90     # HLFS prerequisites
    91     check_version "2.6.2" "$(uname -r)"                                  "KERNEL"
    92     check_version "3.0"   "$BASH_VERSION"                                "BASH"
    93     check_version "3.0"   "$(gcc -dumpversion)"                          "GCC"
    94     check_version "1.14"  "$(tar --version | head -n1 | cut -d" " -f4)"  "TAR"
    95   fi
     81  check_version "2.6.2"   "`uname -r`"          "KERNEL"
     82  check_version "3.0"     "$BASH_VERSION"       "BASH"
     83  check_version "3.0.1"   "`gcc -dumpversion`"  "GCC"
     84  libcVer="`/lib/libc.so.6 | head -n1`"
     85  libcVer="${libcVer##*version }"
     86  check_version "2.2.5"   ${libcVer%%,*}        "GLIBC"
     87  check_version "2.12"    "$(ld --version  | head -n1 | cut -d" " -f4)"        "BINUTILS"
     88  check_version "1.15"    "$(tar --version | head -n1 | cut -d" " -f4)"        "TAR"
     89  bzip2Ver="$(bzip2 --version 2>&1 < /dev/null | head -n1 | cut -d" " -f8)"
     90  check_version "1.0.2"   "${bzip2Ver%%,*}"                                    "BZIP2"
     91  check_version "1.875"   "$(bison --version | head -n1 | cut -d" " -f4)"      "BISON"
     92  check_version "5.2.1"   "$(chown --version | head -n1 | cut -d")" -f2)"      "COREUTILS"
     93  check_version "2.8"     "$(diff --version  | head -n1 | cut -d" " -f4)"      "DIFF"
     94  check_version "4.1.20"  "$(find --version  | head -n1 | cut -d" " -f4)"      "FIND"
     95  check_version "3.0"     "$(gawk --version  | head -n1 | cut -d" " -f3)"      "GAWK"
     96  check_version "2.5"     "$(grep --version  | head -n1 | awk '{print $NF}')"  "GREP"
     97  check_version "1.2.4"   "$(gzip --version 2>&1 | head -n1 | cut -d" " -f2)"  "GZIP"
     98  check_version "3.79.1"  "$(make --version  | head -n1 | cut -d " " -f3 | cut -c1-4)"  "MAKE"
     99  check_version "2.5.4"   "$(patch --version | head -n1 | cut -d" " -f2)"      "PATCH"
     100  check_version "3.0.2"   "$(sed --version   | head -n1 | cut -d" " -f4)"      "SED"
    96101
    97102  # Check for minimum sudo version
     
    126131XML_FILE="<?xml version='1.0' encoding='ISO-8859-1'?>
    127132<?xml-stylesheet type='text/xsl' href='http://docbook.sourceforge.net/release/xsl/1.69.1/xhtml/docbook.xsl'?>
    128 <!DOCTYPE article PUBLIC '-//OASIS//DTD DocBook XML V4.4//EN'
    129   'http://www.oasis-open.org/docbook/xml/4.4/docbookx.dtd'>
     133<!DOCTYPE article PUBLIC '-//OASIS//DTD DocBook XML V4.5//EN'
     134  'http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd'>
    130135<article>
    131136  <title>Test file</title>
     
    138143    if [[ -z "$DEP_DBXML" ]] ; then
    139144      if `echo $XML_FILE | xmllint -noout -postvalid - 2>/dev/null` ; then
    140         check_version "4.4" "4.4" "DocBook XML DTD"
     145        check_version "4.5" "4.5" "DocBook XML DTD"
    141146      else
    142         echo "Warning: not found a working DocBook XML DTD 4.4 installation"
     147        echo "Warning: not found a working DocBook XML DTD 4.5 installation"
    143148        exit 2
    144149      fi
    145150    fi
    146151
    147     if [[ -z "$DEP_DBXSL" ]] ; then
    148       if `echo $XML_FILE | xsltproc --noout - 2>/dev/null` ; then
    149         check_version "1.69.1" "1.69.1" "DocBook XSL"
    150       else
    151         echo "Warning: not found a working DocBook XSL 1.69.1 installation"
    152         exit 2
    153       fi
    154     fi
     152#     if [[ -z "$DEP_DBXSL" ]] ; then
     153#       if `echo $XML_FILE | xsltproc --noout - 2>/dev/null` ; then
     154#         check_version "1.69.1" "1.69.1" "DocBook XSL"
     155#       else
     156#         echo "Warning: not found a working DocBook XSL 1.69.1 installation"
     157#         exit 2
     158#       fi
     159#     fi
    155160
    156161  fi # end BLFS_TOOL=Y
Note: See TracChangeset for help on using the changeset viewer.