For now, don't turn on -Wcast-align by default. There are at least some
authorGuy Harris <guy@alum.mit.edu>
Thu, 27 Jun 2013 10:35:06 +0000 (10:35 -0000)
committerGuy Harris <guy@alum.mit.edu>
Thu, 27 Jun 2013 10:35:06 +0000 (10:35 -0000)
bugs it points out that probably mean the code won't work on machines
that require alignment (e.g., SPARC machines), but we'll turn it on once
we fix them.  (clang is fussier than GCC about this.)

svn path=/trunk/; revision=50187

CMakeLists.txt
configure.ac

index 46826ba11eb0e8bc08bbb2f45d8980a42f9fbea5..2f023677e49556ee7ba2960edcdc1726223dd6cf 100644 (file)
@@ -124,7 +124,6 @@ set(WIRESHARK_C_FLAGS
        -Wendif-labels
        -Wpointer-arith
        -Warray-bounds
-       -Wcast-align
        -Wformat-security
        -Wshorten-64-to-32
        -Wvla
@@ -161,6 +160,7 @@ set(WIRESHARK_EXTRA_C_FLAGS
        -fstrict-overflow -Wstrict-overflow=4
        -Wunreachable-code
        -Wunsafe-loop-optimizations
+       -Wcast-align
        -Wcast-qual
        -Wformat-security
        -Wredundant-decls
index da7d663e32332069ea199cf73869bbb506562221..707ed4c442fc0b050cb14c6160435f10683f5556 100644 (file)
@@ -561,6 +561,11 @@ AC_ARG_ENABLE(extra-gcc-checks,
                #
                AC_WIRESHARK_GCC_CFLAGS_CHECK(-Wmissing-prototypes)
                AC_WIRESHARK_GCC_CFLAGS_CHECK(-Wmissing-declarations)
+               #
+               # A bunch of "that might not work on SPARC" code blocks
+               # this one for now.
+               #
+               AC_WIRESHARK_GCC_CFLAGS_CHECK(-Wcast-align)
        fi
 ],)
 AC_WIRESHARK_GCC_CFLAGS_CHECK(-Wall -W) # -W is now known as -Wextra
@@ -570,7 +575,6 @@ AC_WIRESHARK_GCC_CFLAGS_CHECK(-Wendif-labels)
 AC_WIRESHARK_GCC_CFLAGS_CHECK(-Wpointer-arith)
 AC_WIRESHARK_GCC_CFLAGS_CHECK(-Wno-pointer-sign, C)
 AC_WIRESHARK_GCC_CFLAGS_CHECK(-Warray-bounds)
-AC_WIRESHARK_GCC_CFLAGS_CHECK(-Wcast-align)
 AC_WIRESHARK_GCC_CFLAGS_CHECK(-Wformat-security)
 AC_WIRESHARK_GCC_CFLAGS_CHECK(-Wold-style-definition, C)
 AC_WIRESHARK_GCC_CFLAGS_CHECK(-Wshorten-64-to-32)