libreplace: use HAVE___ATTRIBUTE__ instead of __GNUC__
authorDouglas Bagnall <douglas.bagnall@catalyst.net.nz>
Wed, 23 Mar 2016 02:26:03 +0000 (15:26 +1300)
committerUri Simchoni <uri@samba.org>
Thu, 24 Mar 2016 14:13:15 +0000 (15:13 +0100)
Signed-off-by: Douglas Bagnall <douglas.bagnall@catalyst.net.nz>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
Reviewed-by: Uri Simchoni <uri@samba.org>
lib/replace/replace.h

index c764d06fb245e3460dc0ba5c3f7a9b6bc4435b8e..7080373342a13a541549bed6395d31ec78b35afb 100644 (file)
@@ -425,7 +425,7 @@ int rep_dlclose(void *handle);
 #endif
 
 #ifndef PRINTF_ATTRIBUTE
-#if (__GNUC__ >= 3) && (__GNUC_MINOR__ >= 1 )
+#ifdef HAVE___ATTRIBUTE__
 /** Use gcc attribute to check printf fns.  a1 is the 1-based index of
  * the parameter containing the format, and a2 the index of the first
  * argument. Note that some gcc 2.x versions don't handle this
@@ -437,7 +437,7 @@ int rep_dlclose(void *handle);
 #endif
 
 #ifndef _DEPRECATED_
-#if (__GNUC__ >= 3) && (__GNUC_MINOR__ >= 1 )
+#ifdef HAVE___ATTRIBUTE__
 #define _DEPRECATED_ __attribute__ ((deprecated))
 #else
 #define _DEPRECATED_