fix regression in mirtoconf output introduced in cid 1004EFE6D783E94B328

This commit is contained in:
tg 2012-02-17 13:59:56 +00:00
parent 753891419d
commit 9f3299df4d
1 changed files with 20 additions and 17 deletions

View File

@ -1,5 +1,5 @@
#!/bin/sh #!/bin/sh
srcversion='$MirOS: src/bin/mksh/Build.sh,v 1.509 2012/02/17 09:49:45 tg Exp $' srcversion='$MirOS: src/bin/mksh/Build.sh,v 1.510 2012/02/17 13:59:56 tg Exp $'
#- #-
# Copyright (c) 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010, # Copyright (c) 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010,
# 2011, 2012 # 2011, 2012
@ -155,7 +155,7 @@ ac_testnnd() {
else else
fr=0 fr=0
fi fi
ac_testinit "$@" || return ac_testinit "$@" || return 1
cat >conftest.c cat >conftest.c
vv ']' "$CC $CFLAGS $CPPFLAGS $LDFLAGS $NOWARN conftest.c $LIBS $ccpr" vv ']' "$CC $CFLAGS $CPPFLAGS $LDFLAGS $NOWARN conftest.c $LIBS $ccpr"
test $tcfn = no && test -f a.out && tcfn=a.out test $tcfn = no && test -f a.out && tcfn=a.out
@ -174,9 +174,10 @@ ac_testnnd() {
test $ct = sunpro && vscan='-e ignored -e turned.off' test $ct = sunpro && vscan='-e ignored -e turned.off'
fi fi
test -n "$vscan" && grep $vscan vv.out >/dev/null 2>&1 && fv=$fr test -n "$vscan" && grep $vscan vv.out >/dev/null 2>&1 && fv=$fr
return 0
} }
ac_testn() { ac_testn() {
ac_testnnd "$@" ac_testnnd "$@" || return
rmf conftest.c conftest.o ${tcfn}* vv.out rmf conftest.c conftest.o ${tcfn}* vv.out
ac_testdone ac_testdone
} }
@ -1265,7 +1266,7 @@ else
#define EXTERN #define EXTERN
#define MKSH_INCLUDES_ONLY #define MKSH_INCLUDES_ONLY
#include "sh.h" #include "sh.h"
__RCSID("$MirOS: src/bin/mksh/Build.sh,v 1.509 2012/02/17 09:49:45 tg Exp $"); __RCSID("$MirOS: src/bin/mksh/Build.sh,v 1.510 2012/02/17 13:59:56 tg Exp $");
int main(void) { printf("Hello, World!\n"); return (0); } int main(void) { printf("Hello, World!\n"); return (0); }
EOF EOF
case $cm in case $cm in
@ -1550,7 +1551,7 @@ eval test 1 = \$HAVE_COMPILE_TIME_ASSERTS_$$ || exit 1
# #
$e "${bi}run-time checks follow$ao, please ignore any weird errors" $e "${bi}run-time checks follow$ao, please ignore any weird errors"
ac_testnnd silent_idivwrapv '' '(run-time) whether signed integer division overflows wrap silently' <<-'EOF' if ac_testnnd silent_idivwrapv '' '(run-time) whether signed integer division overflows wrap silently' <<-'EOF'
#define MKSH_INCLUDES_ONLY #define MKSH_INCLUDES_ONLY
#include "sh.h" #include "sh.h"
#ifdef SIGFPE #ifdef SIGFPE
@ -1581,19 +1582,21 @@ ac_testnnd silent_idivwrapv '' '(run-time) whether signed integer division overf
} }
#endif #endif
EOF EOF
if test $fv = 0; then then
echo "| hrm, compiling this failed, but we will just failback" if test $fv = 0; then
else echo "| hrm, compiling this failed, but we will just failback"
echo "| running test programme; this will fail if cross-compiling" else
echo "| in which case we will gracefully degrade to the default" echo "| running test programme; this will fail if cross-compiling"
./$tcfn >vv.out 2>&1 echo "| in which case we will gracefully degrade to the default"
rv=$? ./$tcfn >vv.out 2>&1
echo "| result: `cat vv.out`" rv=$?
fv=0 echo "| result: `cat vv.out`"
test $rv = 0 && test x"`cat vv.out`" = x"si" && fv=1 fv=0
test $rv = 0 && test x"`cat vv.out`" = x"si" && fv=1
fi
rmf conftest.c conftest.o ${tcfn}* vv.out
ac_testdone
fi fi
rmf conftest.c conftest.o ${tcfn}* vv.out
ac_testdone
ac_cppflags ac_cppflags
$e "${bi}end of run-time checks$ao" $e "${bi}end of run-time checks$ao"