backtrace: Refactor ast_bt_get_symbols so it doesn't crash
[asterisk/asterisk.git] / bootstrap.sh
index 02392eb..3843c9a 100755 (executable)
@@ -9,29 +9,27 @@ check_for_app() {
        fi
 }
 
-uname -s | grep -q FreeBSD
-if [ $? = 0 ]
-then
-       check_for_app aclocal19
-       check_for_app autoconf259
-       check_for_app autoheader259
-       check_for_app automake19
+# OpenBSD: pkg_add autoconf%2.63 automake%1.9 metaauto
+test -n "$AUTOCONF_VERSION" || export AUTOCONF_VERSION=2.63
+test -n "$AUTOMAKE_VERSION" || export AUTOMAKE_VERSION=1.9
 
-       aclocal19 2>/dev/null
-       autoconf259
-       autoheader259
-       automake19 --add-missing --copy 2>/dev/null
-else
-       export AUTOCONF_VERSION=2.59
-       export AUTOMAKE_VERSION=1.9
+check_for_app autoconf
+check_for_app autoheader
+check_for_app automake
+check_for_app aclocal
 
-       check_for_app aclocal
-       check_for_app autoconf
-       check_for_app autoheader
-       check_for_app automake
+gen_configure() {
+       echo "Generating the configure script for $1 ..."
+       shift
 
-       aclocal 2>/dev/null
+       aclocal -I "$@"
        autoconf
        autoheader
        automake --add-missing --copy 2>/dev/null
-fi
+}
+
+gen_configure "Asterisk" autoconf `find third-party -path '*/*/*' -prune -o -type d -print | xargs -I {} echo -I {}`
+cd menuselect
+gen_configure "menuselect" ../autoconf
+
+exit 0