From ff76f8e5b4ceb24a2de2ea8b51db065f3c730312 Mon Sep 17 00:00:00 2001 From: Sam Lantinga Date: Thu, 31 Aug 2017 15:17:59 -0700 Subject: [PATCH] Fixed bug 3791 - SDL_bits.h: __builtin_clz is supported in gcc >= 3.4 Ozkan Sezer __builtin_clz is supported in gcc >= 3.4. The following patchlet adjusts SDL_bits.h for it. --- include/SDL_bits.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/include/SDL_bits.h b/include/SDL_bits.h index 60cedc414..bc2857290 100644 --- a/include/SDL_bits.h +++ b/include/SDL_bits.h @@ -60,7 +60,7 @@ extern _inline int _SDL_clz_watcom (Uint32); SDL_FORCE_INLINE int SDL_MostSignificantBitIndex32(Uint32 x) { -#if defined(__GNUC__) && __GNUC__ >= 4 +#if defined(__GNUC__) && (__GNUC__ >= 4 || (__GNUC__ == 3 && __GNUC_MINOR__ >= 4)) /* Count Leading Zeroes builtin in GCC. * http://gcc.gnu.org/onlinedocs/gcc-4.3.4/gcc/Other-Builtins.html */