$OpenBSD: patch-lib_crc32_c,v 1.1 2017/07/25 12:08:36 jca Exp $

gcc-4.2.1 doesn't have __builtin_bswap32

Index: lib/crc32.c
--- lib/crc32.c.orig
+++ lib/crc32.c
@@ -615,7 +615,7 @@ static const uint32_t crc32_lookup[16][256] =
 /* swap endianness */
 static uint32_t swap(uint32_t x)
 {
-#if defined(__GNUC__) || defined(__clang__)
+#if (defined(__GNUC__) && (__GNUC__ > 4 || (__GNUC__ == 4 && __GNUC_MINOR__ >= 3))) || defined(__clang__)
     return __builtin_bswap32(x);
 #else
     return (x >> 24) |
