summaryrefslogtreecommitdiffstats
path: root/autogen.sh
blob: 1c2e51a6ac2998998f6e47b946cd3e1ae589755b (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
#!/bin/sh
set -e

mkdir -p ac
aclocal
autoheader
automake -a -c
autoconf
rm -rf autom4te.cache || true

if [ $# -lt 1 ] ; then
	exit 0
fi

if [ "x$1" = "x--configure" ] ; then
	shift
	repreprodir="`pwd`"
	if [ $# -gt 0 ] ; then
		mkdir -p -- "$1"
		cd "$1" || exit 1
		shift
	fi
	"$repreprodir"/configure --enable-maintainer-mode CFLAGS="-Wall -O2 -g -Wmissing-prototypes -Wstrict-prototypes -Wshadow -Wunused-parameter -Wsign-compare" CPPFLAGS="" "$@"
else
	echo "unsupported option $1" >&2
	exit 1
fi