]> git.ipfire.org Git - thirdparty/ccache.git/commitdiff
Fix clang warning with older compiler versions
authorAnders F Björklund <anders.f.bjorklund@gmail.com>
Thu, 3 Jan 2019 15:57:02 +0000 (16:57 +0100)
committerJoel Rosdahl <joel@rosdahl.net>
Thu, 3 Jan 2019 21:01:08 +0000 (22:01 +0100)
Don't hardcode the clang version, apparently clang-3.8
did have the warning even though clang-3.4 did not...

configure.ac

index a223412779dd0c13602eca74531fc02970273367..e8c34dbecf21d4f9871cee6edd69ff477d8e20fb 100644 (file)
@@ -231,7 +231,7 @@ cat <<EOF >config.h.tmp
 #define CCACHE_CONFIG_H
 #ifdef __clang__
 #pragma clang diagnostic push
-#if __clang_major__ >= 4
+#if __has_warning("-Wreserved-id-macro")
 #pragma clang diagnostic ignored "-Wreserved-id-macro"
 #endif
 #endif