summaryrefslogtreecommitdiff
path: root/cflags.SH
diff options
context:
space:
mode:
authorJarkko Hietaniemi <jhi@iki.fi>2006-09-13 23:19:04 +0300
committerSteve Peters <steve@fisharerojo.org>2006-09-14 01:36:13 +0000
commit7e827271d645402804a156e9a8b9edddac65bd6a (patch)
tree727012241e3f3db6dad2d3b036e427b11743a0c0 /cflags.SH
parentf7a67166576aeda0086a243ed96f9d5fecb33772 (diff)
downloadperl-7e827271d645402804a156e9a8b9edddac65bd6a.tar.gz
(1) g++ 4.x (or Mac OS X) (2) Solaris g++ or CC
Message-ID: <45083D88.7050207@iki.fi> Plus a tweak to the name of CC. p4raw-id: //depot/perl@28842
Diffstat (limited to 'cflags.SH')
-rwxr-xr-xcflags.SH21
1 files changed, 20 insertions, 1 deletions
diff --git a/cflags.SH b/cflags.SH
index cc369d9ccd..966901a935 100755
--- a/cflags.SH
+++ b/cflags.SH
@@ -225,7 +225,26 @@ for file do
esac
case "$cc" in
-*g++*) ccflags="`echo $ccflags|sed 's/-Wdeclaration-after-statement/ /'`" ;;
+*g++*)
+ # We need to remove this also in here (removed early earlier).
+ ccflags="`echo $ccflags|sed 's/-Wdeclaration-after-statement/ /'`"
+ ;;
+esac
+
+case "$cc" in
+*g++*)
+ # Without -Wno-unused-variable g++ 4.x compiles are rather unwatchable
+ # because of all the warnings about Perl___notused, and g++ doesn't
+ # do __attribute__((unused)) (and even if at some stage it will), people
+ # do have older gcc installations. Yes, we lose some valid warnings.
+ for o in -Wno-unused-variable
+ do
+ case "$warn" in
+ *$o*) ;;
+ *) warn="$warn $o" ;;
+ esac
+ done
+ ;;
esac
if test -f .patch; then