Don't use compiler options not supported by clang in XCode 4.6.3
authorMichael Tüxen <tuexen@fh-muenster.de>
Sun, 14 Jul 2013 12:39:25 +0000 (12:39 -0000)
committerMichael Tüxen <tuexen@fh-muenster.de>
Sun, 14 Jul 2013 12:39:25 +0000 (12:39 -0000)
on Apple platforms.

svn path=/trunk/; revision=50576

CMakeLists.txt

index e19fb40348867bd377ce3e4c4d13683f6b94b8cb..0a9e755be528b009bc3f56f7a48db5c2b538853b 100644 (file)
@@ -132,27 +132,31 @@ set(WIRESHARK_C_FLAGS
        -Wattributes
        -Wdiv-by-zero
        -Wignored-qualifiers
        -Wattributes
        -Wdiv-by-zero
        -Wignored-qualifiers
-       -Wpragmas
        -Wno-overlength-strings
        -Wwrite-strings
        -Wno-long-long
 )
 if (NOT APPLE)
        -Wno-overlength-strings
        -Wwrite-strings
        -Wno-long-long
 )
 if (NOT APPLE)
-       set(WIRESHARK_C_FLAGS ${WIRESHARK_C_FLAGS} -fexcess-precision=fast)
+       set(WIRESHARK_C_FLAGS ${WIRESHARK_C_FLAGS}
+           -fexcess-precision=fast
+           -Wpragmas)
 endif()
 
 set(WIRESHARK_C_ONLY_FLAGS
        # The following are C only, not C++
        -Wc++-compat
        -Wdeclaration-after-statement
 endif()
 
 set(WIRESHARK_C_ONLY_FLAGS
        # The following are C only, not C++
        -Wc++-compat
        -Wdeclaration-after-statement
-       -Wlogical-op
        -Wshadow
        -Wno-pointer-sign
        -Wold-style-definition
        -Wshadow
        -Wstrict-prototypes
        -Wshadow
        -Wno-pointer-sign
        -Wold-style-definition
        -Wshadow
        -Wstrict-prototypes
-       -Wjump-misses-init
 )
 )
+if (NOT APPLE)
+       set(WIRESHARK_C_ONLY_FLAGS ${WIRESHARK_C_ONLY_FLAGS}
+           -Wlogical-op
+           -Wjump-misses-init)
+endif()
 
 set(WIRESHARK_EXTRA_C_FLAGS
        -pedantic
 
 set(WIRESHARK_EXTRA_C_FLAGS
        -pedantic