]> git.saurik.com Git - cycript.git/blame_incremental - autogen.sh
Detect all lexer state errors, and show line number.
[cycript.git] / autogen.sh
... / ...
CommitLineData
1#!/usr/bin/env bash
2set -e
3shopt -s expand_aliases extglob
4unalias -a
5libdirs=()
6case `uname` in
7(Linux)
8 libdirs=('/usr/share/gettext')
9 ;;
10(FreeBSD)
11 alias sed=gsed
12 ;;
13(Darwin)
14 alias sed=gsed libtoolize=glibtoolize
15 ;;
16esac
17aclocal
18sed -e 's/AC_PROG_AWK/dnl &/' -i aclocal.m4
19cat `aclocal --print-ac-dir`/ax_check_gnu_make.m4 !(aclocal).m4 >> aclocal.m4
20function filter()
21{
22 sed -e '/no proper invocation of AM_INIT_AUTOMAKE was found\./d' \
23 -e '/You should verify that configure\.ac invokes AM_INIT_AUTOMAKE,/d' \
24 -e '/that aclocal\.m4 is present in the top-level directory,/d' \
25 -e '/and that aclocal\.m4 was recently regenerated (using aclocal)\./d' \
26 -e "/no \`Makefile\.am' found for any configure output/d" \
27 -e "/Consider adding \`AC_CONFIG_MACRO_DIR(\[m4\])' to configure\.ac and/d" \
28 -e '/rerunning g\?libtoolize, to keep the correct libtool macros in-tree\./d' \
29 -e "/Consider adding \`-I m4' to ACLOCAL_AMFLAGS in Makefile\.am\./d"
30}
31automake -acf 2>&1 | filter
32for libdir in ${libdirs[*]}; do
33 automake -acf --libdir $libdir 2>&1 | filter
34done
35libtoolize -ci | filter
36autoconf