2 # Run this to set up the build system: configure, makefiles, etc.
3 # (at one point this was based on the version in enlightenment's cvs)
5 package
="gmpc-coveramazon"
9 test -z "$srcdir" && srcdir
=.
12 AM_VERSIONGREP
="sed -e s/.*[^0-9\.]\([0-9]\.[0-9]\).*/\1/"
13 AC_VERSIONGREP
="sed -e s/.*[^0-9\.]\([0-9]\.[0-9][0-9]\).*/\1/"
14 VERSIONMKINT
="sed -e s/[^0-9]//"
15 if test -n "$AM_FORCE_VERSION"
17 AM_VERSIONS
="$AM_FORCE_VERSION"
19 AM_VERSIONS
='1.6 1.7 1.8 1.9'
21 if test -n "$AC_FORCE_VERSION"
23 AC_VERSIONS
="$AC_FORCE_VERSION"
25 AC_VERSIONS
='2.58 2.59'
31 needed_int
=`echo $VERNEEDED | $VERSIONMKINT`
34 i_int
=`echo $i | $VERSIONMKINT`
35 if test $i_int -ge $needed_int
37 echo $bin-$i $bin$i $bin-$i_int $bin$i_int
43 for c
in autoconf autoheader automake aclocal
45 uc
=`echo $c | tr a-z A-Z`
46 eval "val=`echo '$'$uc`"
49 echo "$uc=$val in environment, will not attempt to auto-detect"
55 VERNEEDED
=`fgrep AC_PREREQ configure.ac | $AC_VERSIONGREP`
56 VERSIONS
="$AC_VERSIONS"
60 VERNEEDED
=`fgrep AUTOMAKE_OPTIONS Makefile.am | $AM_VERSIONGREP`
61 VERSIONS
="$AM_VERSIONS"
65 printf "checking for $c ... "
66 for x
in `versioned_bins $c`; do
67 ($x --version < /dev
/null
> /dev
/null
2>&1) > /dev
/null
2>&1
75 eval "val=`echo '$'$uc`"
80 DIE
="$DIE $c=$VERNEEDED"
82 DIE
="$DIE $c($pkg)=$VERNEEDED"
87 if test -n "$LIBTOOLIZE"
89 echo "LIBTOOLIZE=$LIBTOOLIZE in environment," \
90 "will not attempt to auto-detect"
92 printf "checking for libtoolize ... "
93 for x
in libtoolize glibtoolize
95 ($x --version < /dev
/null
> /dev
/null
2>&1) > /dev
/null
2>&1
105 if test -z "$LIBTOOLIZE"
107 DIE
="$DIE libtoolize(libtool)"
112 echo "You must have the following installed to compile $package:"
116 echo $i |
sed -e 's/(/ (from /' -e 's/=\(.*\)/ (>= \1)/'
118 echo "Download the appropriate package(s) for your system,"
119 echo "or get the source from one of the GNU ftp sites"
120 echo "listed in http://www.gnu.org/order/ftp.html"
124 echo "Generating configuration files for $package, please wait...."
126 ACLOCAL_FLAGS
="$ACLOCAL_FLAGS"
128 # /usr/share/aclocal is most likely included by default, already...
130 /usr/local/share/aclocal
132 /usr/pkg/share/aclocal
134 /usr/gnu/share/aclocal
137 for i
in $ac_local_paths; do
138 if test -d "$i"; then
139 ACLOCAL_FLAGS
="$ACLOCAL_FLAGS -I $i"
140 # we probably only want one of these...
145 echo " $ACLOCAL $ACLOCAL_FLAGS"
146 $ACLOCAL $ACLOCAL_FLAGS ||
exit 1
149 $AUTOHEADER ||
exit 1
151 echo " $LIBTOOLIZE --automake"
152 $LIBTOOLIZE --automake ||
exit 1
154 echo " $AUTOMAKE --add-missing $AUTOMAKE_FLAGS"
155 $AUTOMAKE --add-missing $AUTOMAKE_FLAGS ||
exit 1
161 if test x
$NOCONFIGURE = x
; then
162 "$srcdir"/configure
"$@" ||
exit 1