$OpenBSD: patch-include_lcms_h,v 1.8 2009/04/09 13:10:49 jasper Exp $
--- include/lcms.h.orig	Thu Apr  9 13:56:40 2009
+++ include/lcms.h	Thu Apr  9 13:59:19 2009
@@ -143,17 +143,17 @@ typedef    pthread_rwlock_t      LCMS_RWLOCK_T;
 #   define USE_BIG_ENDIAN      1
 #endif
 
-#if TARGET_CPU_PPC
+#if defined(TARGET_CPU_PPC) && TARGET_CPU_PPC
 #   define USE_BIG_ENDIAN   1
 #endif
 
-#if macintosh
+#if defined(macintosh) && macintosh
 # ifndef __LITTLE_ENDIAN__
 #   define USE_BIG_ENDIAN      1
 # endif
 #endif
 
-#ifdef __BIG_ENDIAN__
+#if defined(__BIG_ENDIAN__) && __BIG_ENDIAN__
 #   define USE_BIG_ENDIAN      1
 #endif
 
@@ -1415,7 +1415,6 @@ LCMS_INLINE WORD _cmsClampWord(int in)
 LCMS_INLINE void* _cmsMalloc(size_t size)
 {
     if (size > ((size_t) 1024*1024*500)) return NULL;  // Never allow over 500Mb
-    if (size < 0) return NULL;              // Prevent signed size_t exploits
 
     return (void*) malloc(size);
 }
