~ubuntu-branches/ubuntu/natty/lighttpd/natty

1.1.10 by Stephan Hermann
Import upstream version 1.4.19
1
#!/bin/sh
2
# Run this to generate all the initial makefiles, etc.
3
4
LIBTOOLIZE_FLAGS="--copy --force"
1.1.13 by Krzysztof Krzyżaniak (eloy)
Import upstream version 1.4.24
5
AUTOMAKE_FLAGS="--add-missing --copy --foreign"
1.1.10 by Stephan Hermann
Import upstream version 1.4.19
6
7
ARGV0=$0
1.1.13 by Krzysztof Krzyżaniak (eloy)
Import upstream version 1.4.24
8
ARGS="$@"
1.1.10 by Stephan Hermann
Import upstream version 1.4.19
9
10
11
run() {
1.1.13 by Krzysztof Krzyżaniak (eloy)
Import upstream version 1.4.24
12
	echo "$ARGV0: running \`$@' $ARGS"
13
	$@ $ARGS
1.1.10 by Stephan Hermann
Import upstream version 1.4.19
14
}
15
1.1.13 by Krzysztof Krzyżaniak (eloy)
Import upstream version 1.4.24
16
## jump out if one of the programs returns 'false'
17
set -e
18
19
## on macosx glibtoolize, others have libtool
20
if test x$LIBTOOLIZE = x; then
21
  if test \! "x`which glibtoolize 2> /dev/null | grep -v '^no'`" = x; then
22
    LIBTOOLIZE=glibtoolize
23
  elif test \! "x`which libtoolize-1.5 2> /dev/null | grep -v '^no'`" = x; then
24
    LIBTOOLIZE=libtoolize-1.5
25
  elif test \! "x`which libtoolize 2> /dev/null | grep -v '^no'`" = x; then
26
    LIBTOOLIZE=libtoolize
27
  else 
28
    echo "libtoolize 1.5.x wasn't found, exiting"; exit 0
29
  fi
30
fi
31
32
## suse has aclocal and aclocal-1.9
33
if test x$ACLOCAL = x; then
34
  if test \! "x`which aclocal-1.9 2> /dev/null | grep -v '^no'`" = x; then
35
    ACLOCAL=aclocal-1.9
36
  elif test \! "x`which aclocal19 2> /dev/null | grep -v '^no'`" = x; then
37
    ACLOCAL=aclocal19
38
  elif test \! "x`which aclocal 2> /dev/null | grep -v '^no'`" = x; then
39
    ACLOCAL=aclocal
40
  else 
41
    echo "automake 1.9.x (aclocal) wasn't found, exiting"; exit 0
42
  fi
43
fi
44
45
if test x$AUTOMAKE = x; then
46
  if test \! "x`which automake-1.9 2> /dev/null | grep -v '^no'`" = x; then
47
    AUTOMAKE=automake-1.9
48
  elif test \! "x`which automake19 2> /dev/null | grep -v '^no'`" = x; then
49
    AUTOMAKE=automake19
50
  elif test \! "x`which automake 2> /dev/null | grep -v '^no'`" = x; then
51
    AUTOMAKE=automake
52
  else 
53
    echo "automake 1.9.x wasn't found, exiting"; exit 0
54
  fi
55
fi
56
57
58
## macosx has autoconf-2.59 and autoconf-2.60
59
if test x$AUTOCONF = x; then
60
  if test \! "x`which autoconf-2.59 2> /dev/null | grep -v '^no'`" = x; then
61
    AUTOCONF=autoconf-2.59
62
  elif test \! "x`which autoconf259 2> /dev/null | grep -v '^no'`" = x; then
63
    AUTOCONF=autoconf259
64
  elif test \! "x`which autoconf 2> /dev/null | grep -v '^no'`" = x; then
65
    AUTOCONF=autoconf
66
  else 
67
    echo "autoconf 2.59+ wasn't found, exiting"; exit 0
68
  fi
69
fi
70
71
if test x$AUTOHEADER = x; then
72
  if test \! "x`which autoheader-2.59 2> /dev/null | grep -v '^no'`" = x; then
73
    AUTOHEADER=autoheader-2.59
74
  elif test \! "x`which autoheader259 2> /dev/null | grep -v '^no'`" = x; then
75
    AUTOHEADER=autoheader259
76
  elif test \! "x`which autoheader 2> /dev/null | grep -v '^no'`" = x; then
77
    AUTOHEADER=autoheader
78
  else 
79
    echo "autoconf 2.59+ (autoheader) wasn't found, exiting"; exit 0
80
  fi
81
fi
82
83
mkdir -p m4
1.1.10 by Stephan Hermann
Import upstream version 1.4.19
84
run $LIBTOOLIZE $LIBTOOLIZE_FLAGS
1.1.13 by Krzysztof Krzyżaniak (eloy)
Import upstream version 1.4.24
85
run $ACLOCAL $ACLOCAL_FLAGS -I m4
1.1.10 by Stephan Hermann
Import upstream version 1.4.19
86
run $AUTOHEADER
87
run $AUTOMAKE $AUTOMAKE_FLAGS
88
run $AUTOCONF
1.1.13 by Krzysztof Krzyżaniak (eloy)
Import upstream version 1.4.24
89
90
if test "$ARGS" = "" ; then
91
  echo "Now type './configure ...' and 'make' to compile."
92
fi