From: Ruben Kerkhof Date: Sun, 14 Aug 2016 20:25:53 +0000 (+0200) Subject: Fix build with older GCCs X-Git-Tag: collectd-5.6.0~21 X-Git-Url: https://git.verplant.org/?a=commitdiff_plain;h=62dc64b7d80d96c4dc563348691a1f60e4f77b58;p=collectd.git Fix build with older GCCs They warn for unknown pragmas --- diff --git a/src/liboconfig/scanner.l b/src/liboconfig/scanner.l index 09de4d2e..2b5dbfb7 100644 --- a/src/liboconfig/scanner.l +++ b/src/liboconfig/scanner.l @@ -33,8 +33,11 @@ #include "aux_types.h" #include "parser.h" +#ifdef __clang__ #pragma clang diagnostic push #pragma clang diagnostic ignored "-Wmissing-noreturn" +#endif + #pragma GCC diagnostic push #pragma GCC diagnostic ignored "-Wsign-compare" @@ -164,5 +167,8 @@ static void ml_append (char *string) return; } /* ml_append */ +#ifdef __clang__ #pragma clang diagnostic pop +#endif + #pragma GCC diagnostic pop