bootstrap
author ladanyi
Tue, 04 Jul 2006 18:54:34 +0000
branchlemon-1.0
changeset 2651 184dcd8c07d0
permissions -rwxr-xr-x
Distribute Doxyfile.in and lemon.pc.in.
ladanyi@2647
     1
#!/bin/bash
ladanyi@2647
     2
ladanyi@2647
     3
quiet=0
ladanyi@2647
     4
function quiet { [[ $quiet == 1 ]]; }
ladanyi@2647
     5
ladanyi@2647
     6
if [[ "$1" == "-q" ]]; then
ladanyi@2647
     7
  quiet=1
ladanyi@2647
     8
  shift
ladanyi@2647
     9
fi
ladanyi@2647
    10
ladanyi@2647
    11
prev=
ladanyi@2647
    12
for option
ladanyi@2647
    13
do
ladanyi@2647
    14
  if test -n "$prev"
ladanyi@2647
    15
  then
ladanyi@2647
    16
    eval "$prev=\$option"
ladanyi@2647
    17
    prev=
ladanyi@2647
    18
    continue
ladanyi@2647
    19
  fi
ladanyi@2647
    20
ladanyi@2647
    21
  optarg=`expr "x$option" : 'x[^=]*=\(.*\)'`
ladanyi@2647
    22
ladanyi@2647
    23
  case $option in
ladanyi@2647
    24
ladanyi@2647
    25
  -amver | --amver)
ladanyi@2647
    26
    prev=amver ;;
ladanyi@2647
    27
  -amver=* | --amver=*)
ladanyi@2647
    28
    amver=$optarg ;;
ladanyi@2647
    29
ladanyi@2647
    30
  -acver | --acver)
ladanyi@2647
    31
    prev=acver ;;
ladanyi@2647
    32
  -acver=* | --acver=*)
ladanyi@2647
    33
    acver=$optarg ;;
ladanyi@2647
    34
ladanyi@2647
    35
  --help | -h)
ladanyi@2647
    36
    cat << EOF
ladanyi@2647
    37
Usage: $0 [OPTION]
ladanyi@2647
    38
ladanyi@2647
    39
Options:
ladanyi@2647
    40
  -h, --help            display this help and exit
ladanyi@2647
    41
      --amver=VERSION   use VERSION version of automake
ladanyi@2647
    42
      --acver=VERSION   use VERSION version of autoconf
ladanyi@2647
    43
ladanyi@2647
    44
Expamle:
ladanyi@2647
    45
  $0 --amver=1.8 --acver=2.59
ladanyi@2647
    46
EOF
ladanyi@2647
    47
    exit 0
ladanyi@2647
    48
    ;;
ladanyi@2647
    49
ladanyi@2647
    50
  *)
ladanyi@2647
    51
    cat << EOF >&2
ladanyi@2647
    52
$0: unrecognized option: $option
ladanyi@2647
    53
Try \`$0 --help' for more information.
ladanyi@2647
    54
EOF
ladanyi@2647
    55
    exit 1
ladanyi@2647
    56
    ;;
ladanyi@2647
    57
ladanyi@2647
    58
  esac
ladanyi@2647
    59
done
ladanyi@2647
    60
ladanyi@2647
    61
automake=automake
ladanyi@2647
    62
aclocal=aclocal
ladanyi@2647
    63
autoconf=autoconf
ladanyi@2647
    64
autoheader=autoheader
ladanyi@2647
    65
ladanyi@2647
    66
if test -n "$amver"
ladanyi@2647
    67
then
ladanyi@2647
    68
  automake=automake-$amver
ladanyi@2647
    69
  aclocal=aclocal-$amver
ladanyi@2647
    70
fi
ladanyi@2647
    71
ladanyi@2647
    72
if test -n "$acver"
ladanyi@2647
    73
then
ladanyi@2647
    74
  autoconf=autoconf-$acver
ladanyi@2647
    75
  autoheader=autoheader-$acver
ladanyi@2647
    76
fi
ladanyi@2647
    77
ladanyi@2647
    78
set -e
ladanyi@2647
    79
quiet || set -x
ladanyi@2647
    80
ladanyi@2647
    81
$aclocal -I m4
ladanyi@2647
    82
(quiet && exec > /dev/null; libtoolize --force --copy)
ladanyi@2647
    83
$autoconf
ladanyi@2647
    84
$autoheader
ladanyi@2647
    85
$automake --add-missing --copy --gnu