[libxml2] Silence clang's -Wunknown-attribute



commit b02a167af3d2a47c155bce123820cbb5fa19dc9c
Author: Michael Catanzaro <mcatanzaro gnome org>
Date:   Tue Apr 14 13:51:01 2015 -0500

    Silence clang's -Wunknown-attribute
    
    Clang doesn't have perfect feature compatibility with GCC,
    unfortunately.
    
    https://bugzilla.gnome.org/show_bug.cgi?id=747870

 include/libxml/xmlversion.h.in |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
---
diff --git a/include/libxml/xmlversion.h.in b/include/libxml/xmlversion.h.in
index 00a836f..b173be9 100644
--- a/include/libxml/xmlversion.h.in
+++ b/include/libxml/xmlversion.h.in
@@ -435,7 +435,7 @@ XMLPUBFUN void XMLCALL xmlCheckVersion(int version);
  */
 
 #ifndef LIBXML_ATTR_ALLOC_SIZE
-# if ((__GNUC__ > 4) || ((__GNUC__ == 4) && (__GNUC_MINOR__ >= 3)))
+# if (!defined(__clang__) && ((__GNUC__ > 4) || ((__GNUC__ == 4) && (__GNUC_MINOR__ >= 3))))
 #  define LIBXML_ATTR_ALLOC_SIZE(x) __attribute__((alloc_size(x)))
 # else
 #  define LIBXML_ATTR_ALLOC_SIZE(x)


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]