From: Martin Willi Date: Wed, 15 Apr 2015 12:20:52 +0000 (+0200) Subject: utils: Support __has_feature() macro on non-LLVM compilers by returning 0 X-Git-Tag: 5.9.8dr4~11^2~17 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=1866d335387eb4657bb323e3b4b2c74f92d65be8;p=thirdparty%2Fstrongswan.git utils: Support __has_feature() macro on non-LLVM compilers by returning 0 --- diff --git a/src/libstrongswan/utils/utils.h b/src/libstrongswan/utils/utils.h index c7ccd3afac..120b159508 100644 --- a/src/libstrongswan/utils/utils.h +++ b/src/libstrongswan/utils/utils.h @@ -112,6 +112,13 @@ void utils_deinit(); #define BUILD_ASSERT_ARRAY(a) \ BUILD_ASSERT(!__builtin_types_compatible_p(typeof(a), typeof(&(a)[0]))) +/** + * LLVM/Clang __has_feature support + */ +#ifndef __has_feature +# define __has_feature(x) 0 +#endif + /** * Debug macro to follow control flow */