aboutsummaryrefslogtreecommitdiff
path: root/libctf/ctf-impl.h
diff options
context:
space:
mode:
Diffstat (limited to 'libctf/ctf-impl.h')
-rw-r--r--libctf/ctf-impl.h5
1 files changed, 5 insertions, 0 deletions
diff --git a/libctf/ctf-impl.h b/libctf/ctf-impl.h
index 2691a68..3217f92 100644
--- a/libctf/ctf-impl.h
+++ b/libctf/ctf-impl.h
@@ -66,8 +66,13 @@ extern "C"
macros glibc may introduce, which have names of the pattern
__attribute_blah__. */
+#if defined (__clang__)
#define _libctf_printflike_(string_index,first_to_check) \
__attribute__ ((__format__ (__printf__, (string_index), (first_to_check))))
+#else
+#define _libctf_printflike_(string_index,first_to_check) \
+ __attribute__ ((__format__ (__gnu_printf__, (string_index), (first_to_check))))
+#endif
#define _libctf_unlikely_(x) __builtin_expect ((x), 0)
#define _libctf_unused_ __attribute__ ((__unused__))
#define _libctf_malloc_ __attribute__((__malloc__))