1 # To be included by ../buildconf.sh .
8 test -d autom4te.cache && rm -r autom4te.cache
9 test -d config || mkdir config
10 if [ "`uname -s`" = FreeBSD ]; then
11 # FreeBSD intalls the various auto* tools with version numbers
12 echo "Using special configuration for FreeBSD ..."
14 aclocal="aclocal -I /usr/local/share/aclocal"
20 if [ "`uname -s`" = Darwin ]; then
21 echo "Using special configuration for Darwin/MacOS ..."
22 libtoolize=glibtoolize
25 if $automake --version|head -1 |grep ' 1\.[4-7]'; then
26 echo "automake 1.4-1.7 is active. You should use automake 1.8 or later"
27 if [ -f /etc/debian_version ]; then
28 echo " sudo apt-get install automake1.9"
29 echo " sudo update-alternatives --config automake"
36 if grep AC_CONFIG_HEADERS configure.ac >/dev/null; then
39 if grep AM_PROG_LIBTOOL configure.ac >/dev/null; then
41 $libtoolize --automake --force
46 $automake --add-missing
49 if [ -f config.cache ]; then
53 enable_configure=false
59 sh_cflags="-g -Wall -Wdeclaration-after-statement -Wstrict-prototypes"
60 sh_cxxflags="-g -Wall"
74 if $enable_configure; then
75 if [ -n "$sh_cflags" ]; then
77 CFLAGS="$sh_cflags" CXXFLAGS="$sh_cxxflags" ./configure \
78 --disable-shared --enable-static --with-pic $*
80 CFLAGS="$sh_cflags" CXXFLAGS="$sh_cxxflags" ./configure $*