diff options
author | Quincey Koziol <koziol@hdfgroup.org> | 2002-05-01 13:30:54 (GMT) |
---|---|---|
committer | Quincey Koziol <koziol@hdfgroup.org> | 2002-05-01 13:30:54 (GMT) |
commit | 2491fa05d4b8da306c3c6720d89630d42e75912c (patch) | |
tree | 507ddcd29fdccbac9b53c71c742b5e66088eac27 /config | |
parent | 891ba681eec70026928d0cd05cb98eefb0971758 (diff) | |
download | hdf5-2491fa05d4b8da306c3c6720d89630d42e75912c.zip hdf5-2491fa05d4b8da306c3c6720d89630d42e75912c.tar.gz hdf5-2491fa05d4b8da306c3c6720d89630d42e75912c.tar.bz2 |
[svn-r5302] Purpose:
Configuration improvements
Description:
Added more warning flags to gcc builds, especially with gcc 3+. Also, added
the -Wno-long-long flag to gcc builds to turn off the annoying "long long"
warnings.
Platforms tested:
FreeBSD 4.5 (sleipnir) with gcc 2.95.3 and gcc 3.1 (prerelease)
Diffstat (limited to 'config')
-rw-r--r-- | config/gnu-flags | 20 |
1 files changed, 7 insertions, 13 deletions
diff --git a/config/gnu-flags b/config/gnu-flags index 1938563..e24e1db 100644 --- a/config/gnu-flags +++ b/config/gnu-flags @@ -114,7 +114,7 @@ esac # Host-specific flags case "`hostname`" in - hawkwind.ncsa.uiuc.edu) + sleipnir.ncsa.uiuc.edu) ARCH="$ARCH -pipe" ;; esac @@ -123,7 +123,7 @@ esac case "$cc_vendor-$cc_version" in gcc*|egcs*|pgcc*) # General - CFLAGS="$CFLAGS $ARCH -ansi -pedantic -Wchar-subscripts -Wall -W -Wshadow -Wbad-function-cast -Wcast-qual -Wcast-align -Wwrite-strings -Wstrict-prototypes -Wmissing-prototypes -Wmissing-declarations -Wnested-externs -Winline -Wpointer-arith -Wconversion -Wredundant-decls" + CFLAGS="$CFLAGS $ARCH -ansi -pedantic -Wall -W -Wundef -Wshadow -Wpointer-arith -Wbad-function-cast -Wcast-qual -Wcast-align -Wwrite-strings -Wconversion -Wsign-compare -Waggregate-return -Wstrict-prototypes -Wmissing-prototypes -Wmissing-declarations -Wredundant-decls -Wnested-externs -Winline -Wno-long-long" # Production PROD_CFLAGS="-O2 $NOFP -finline-functions" @@ -160,17 +160,7 @@ case "$cc_vendor-$cc_version" in cc_flags_set=yes ;; - gcc-2.95.[3456789]) - # Start using the C99 Standard's extensions (long long, etc.) - # (Not quite yet... -QAK) - # General - #CFLAGS="$CFLAGS -std=c9x" - - # Flags are set - cc_flags_set=yes - ;; - - gcc-2.95.[12]) + gcc-2.95.*) # No changes from default GCC flags... # Flags are set @@ -178,8 +168,12 @@ case "$cc_vendor-$cc_version" in ;; gcc-3.*) + # Replace -ansi flag with -std=c99 flag CFLAGS="`echo $CFLAGS | sed -e 's/-ansi/-std=c99/g'`" + # Append some extra warning flags that only gcc3+ know about + CFLAGS="$CFLAGS -Wfloat-equal -Wmissing-format-attribute -Wpadded" + # Flags are set cc_flags_set=yes ;; |