X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=blobdiff_plain;f=cflags.SH;h=2e7ecf357d6639eae7d365ff074f823e75aeb5aa;hb=869efde7048cf4e4bafcc463f8d4209a63e0d41a;hp=a52c85052731fd50eae76dff7d03f37a315f75f1;hpb=3e8416a3d479179c18109951e5260dc3c0ae4158;p=p5sagit%2Fp5-mst-13.2.git diff --git a/cflags.SH b/cflags.SH index a52c850..2e7ecf3 100755 --- a/cflags.SH +++ b/cflags.SH @@ -17,6 +17,11 @@ case "$0" in */*) cd `expr X$0 : 'X\(.*\)/'` ;; esac +if test -f config_h.SH -a ! -f config.h; then + . ./config_h.SH + CONFIG_H=already-done +fi + warn='' # Add -Wall for the core modules iff gcc and not already -Wall @@ -114,7 +119,7 @@ case "$gccversion" in '') ;; [12]*) ;; # gcc versions 1 (gasp!) and 2 are not good for this. Intel*) ;; # # Is that you, Intel C++? -*) for opt in -ansi -pedantic -std=c89 -W -Wextra -Wdeclaration-after-statement -Wendif-labels +*) for opt in -ansi -pedantic -std=c89 -W -Wextra -Wdeclaration-after-statement -Wendif-labels -Wc++-compat do case " $ccflags " in *" $opt "*) ;; # Skip if already there. @@ -295,10 +300,11 @@ case "$cc" in # but then whined about. for f in -Wdeclaration-after-statement -std=c89 do - ccflags="`echo $ccflags|sed 's/$f/ /'`" + ccflags=`echo $ccflags|sed 's/$f/ /'` done ;; esac +cppflags=`echo $cppflags|sed 's/-Wdeclaration-after-statement/ /'` case "$cc" in *g++*)