2016-04-12 03:09:29 -05:00
|
|
|
#! /bin/bash
|
|
|
|
|
2018-04-12 14:43:19 -05:00
|
|
|
srcdir=`dirname $0`
|
|
|
|
test -n "$srcdir" || srcdir=.
|
|
|
|
|
|
|
|
olddir=`pwd`
|
|
|
|
cd "$srcdir"
|
|
|
|
|
2016-04-12 03:09:29 -05:00
|
|
|
function failed {
|
|
|
|
cat << EOF 1>&2
|
|
|
|
|
|
|
|
Result: $1 failed
|
|
|
|
|
|
|
|
Please try running the commands from autogen.sh manually, and fix errors.
|
|
|
|
EOF
|
|
|
|
exit 1
|
|
|
|
}
|
|
|
|
|
2018-10-30 04:25:33 -05:00
|
|
|
if test `uname -s` = Linux; then
|
|
|
|
libtoolize || failed "libtool"
|
2019-02-18 09:43:48 -06:00
|
|
|
elif test `uname -s` = Darwin; then
|
2019-02-19 08:30:43 -06:00
|
|
|
echo 'Having glibtoolize is mandatory only if you intend to use the alternative "brew" method. See ios/README.' >&2
|
|
|
|
echo 'So unless you plan to do that, it does not matter if glibtoolize is not be found below:' >&2
|
|
|
|
glibtoolize
|
|
|
|
echo 'There. The script now continues. Errors below are fatal.' >&2
|
2018-10-30 04:25:33 -05:00
|
|
|
fi
|
2016-04-12 03:09:29 -05:00
|
|
|
|
|
|
|
aclocal || failed "aclocal"
|
|
|
|
|
|
|
|
autoheader || failed "autoheader"
|
|
|
|
|
|
|
|
automake --add-missing || failed "automake"
|
|
|
|
|
|
|
|
autoreconf || failed "autoreconf"
|
|
|
|
|
|
|
|
cat << EOF
|
|
|
|
|
2018-04-12 14:43:19 -05:00
|
|
|
Result: All went OK, please run $srcdir/configure (with the appropriate parameters) now.
|
2016-04-12 03:09:29 -05:00
|
|
|
|
|
|
|
EOF
|
2018-04-12 14:43:19 -05:00
|
|
|
|
|
|
|
cd "$olddir"
|