Not yet working stack checking (symbol STACKCHECK)
[gnokii.git] / do
1 #! /bin/sh
2
3 #target_m68k=1
4 enable_debug=1
5 #stack_check=1
6 cfg_port="ttyS0"
7
8 exec 2>&1
9 set -ex
10 rm -f config.cache
11 autoheader
12 autoconf
13 # rm -f config.cache
14 if [ -n "$target_m68k" ];then
15         test -n "$CC"       || export CC="m68k-pic-coff-gcc"
16         test -n "$AR"       || export AR="m68k-pic-coff-ar"
17         test -n "$CFLAGS"   || export CFLAGS="-O2 -Wall -fPIC"
18         test -n "$CPPFLAGS" || export CPPFLAGS="-DUCCOMPAT=1 $CPPFLAGS"
19         if [ -n "$stack_check" -a -n "$enable_debug" ];then
20                 export CPPFLAGS="-DSTACKCHECK=1 $CPPFLAGS"
21         fi
22         test -n "$LDFLAGS"  || export LDFLAGS="gnokii/cleanup.c"
23 #       if [ -n "$enable_debug" ];then
24 #               export CFLAGS="-pg $CFLAGS"
25 #               export LDFLAGS="gnokii/mcount.c $LDFLAGS"
26 #       fi
27 fi
28 export CPPFLAGS="-DUCLINUX=1 $CPPFLAGS"
29 ./configure --with-cfg-model=5110 --with-cfg-port=/dev/"$cfg_port" --without-x \
30                 `if [ -n "$enable_debug" ];then echo "--enable-debug --enable-xdebug";fi`
31 make clean
32 make