summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rwxr-xr-xlib/make/configure6
-rw-r--r--lib/make/configure.in6
-rw-r--r--lib/make/known-architectures/linux37
3 files changed, 13 insertions, 36 deletions
diff --git a/lib/make/configure b/lib/make/configure
index ac45b491..0c0fb256 100755
--- a/lib/make/configure
+++ b/lib/make/configure
@@ -4578,7 +4578,7 @@ fi
if test -z "$C_WARN_FLAGS" ; then
case "$CC" in
gcc)
- C_WARN_FLAGS="-Wall"
+ C_WARN_FLAGS="-Wall -W -Wshadow -Wpointer-arith -Wbad-function-cast -Wcast-qual -Wcast-align -Wstrict-prototypes -Wmissing-prototypes -Wmissing-declarations -Winline"
;;
*)
# Not sure what should be a reasonable default.
@@ -4591,8 +4591,8 @@ fi
if test -z "$CXX_WARN_FLAGS" ; then
case "$CXX" in
- g++)
- CXX_WARN_FLAGS="-Wall"
+ c++ | g++)
+ CXX_WARN_FLAGS="\$(C_WARN_FLAGS) -Woverloaded-virtual"
;;
*)
# Not sure what should be a reasonable default.
diff --git a/lib/make/configure.in b/lib/make/configure.in
index 9c962bd0..d796d163 100644
--- a/lib/make/configure.in
+++ b/lib/make/configure.in
@@ -894,7 +894,7 @@ AC_SUBST(C_WARN_FLAGS)
if test -z "$C_WARN_FLAGS" ; then
case "$CC" in
gcc)
- C_WARN_FLAGS="-Wall"
+ C_WARN_FLAGS="-Wall -W -Wshadow -Wpointer-arith -Wbad-function-cast -Wcast-qual -Wcast-align -Wstrict-prototypes -Wmissing-prototypes -Wmissing-declarations -Winline"
;;
*)
# Not sure what should be a reasonable default.
@@ -907,8 +907,8 @@ AC_SUBST(CXX_WARN_FLAGS)
if test -z "$CXX_WARN_FLAGS" ; then
case "$CXX" in
- g++)
- CXX_WARN_FLAGS="-Wall"
+ c++ | g++)
+ CXX_WARN_FLAGS="\$(C_WARN_FLAGS) -Woverloaded-virtual"
;;
*)
# Not sure what should be a reasonable default.
diff --git a/lib/make/known-architectures/linux b/lib/make/known-architectures/linux
index 0efdc6a1..5d386c87 100644
--- a/lib/make/known-architectures/linux
+++ b/lib/make/known-architectures/linux
@@ -4,9 +4,10 @@
# @date Thu Jul 15 21:30:04 1999
# @author Tom Goodale
# @desc
-#
+# known-architectures file for systems running Linux
# @enddesc
-# @version $Header$
+# @version $Header: /cactusdevcvs/Cactus/lib/make/known-architectures/linux,
+v 1.38 2001/06/14 17:23:01 tradke Exp $
# @@*/
if test "$CCTK_CONFIG_STAGE" = "preferred-compilers" ; then
@@ -189,42 +190,19 @@ else
# C compiler
+# Set the appropriate dependency, warning, and debugging flags
+# Note that the defaults settings are for gcc/g++ and they are set by configure
case "$CC" in
ecc)
: ${C_DEPEND='$(CC) -M $(CPPFLAGS)'}
- ;;
- *)
- :
- ;;
- esac
-
-#Set the appropriate warning and debugging flags
- case "$CC" in
- gcc)
- : ${C_DEBUG_FLAGS="-g"}
- : ${C_WARN_FLAGS="-Wall -W -Wshadow -Wpointer-arith -Wbad-function-cast -Wcast-qual -Wcast-align -Wstrict-prototypes -Wmissing-declarations"}
- ;;
- ecc)
- : ${C_DEBUG_FLAGS="-g"}
: ${C_WARN_FLAGS="-w2"}
;;
*)
- : ${C_DEBUG_FLAGS="-g"}
-# : ${C_WARN_FLAGS="-Wall"}
- ;;
- esac
-
- case "$CXX" in
- [cg]++)
- : ${CXX_DEBUG_FLAGS="-g"}
- : ${CXX_WARN_FLAGS="-Wall -W -Wshadow -Wpointer-arith -Wbad-function-cast -Wcast-qual -Wcast-align -Wstrict-prototypes -Wmissing-declarations"}
- ;;
- *)
- : ${CXX_DEBUG_FLAGS="-g"}
-# : ${C_WARN_FLAGS="-Wall"}
;;
esac
+ : ${C_DEBUG_FLAGS="-g"}
+ : ${CXX_DEBUG_FLAGS="-g"}
# Cache stuff
@@ -294,4 +272,3 @@ else
# This is caught by lib/make/extras/MPI/NATIVE then.
fi
-