2016-01-21 23:40:00 +01:00

25 lines
752 B
Plaintext

$NetBSD: patch-aa,v 1.4 2015/01/23 17:15:09 pho Exp $
Move checks for aligned malloc function from opj_malloc.h to cmake.
See also patch-CMakeLists.txt
--- src/lib/openjp2/opj_malloc.h.orig 2012-11-19 14:26:08.000000000 +0000
+++ src/lib/openjp2/opj_malloc.h
@@ -80,16 +80,6 @@ Allocate memory aligned to a 16 byte bou
#define HAVE_MM_MALLOC
#endif
#endif
-#else /* Not _WIN32 */
- #if defined(__sun)
- #define HAVE_MEMALIGN
- #elif defined(__FreeBSD__)
- #define HAVE_POSIX_MEMALIGN
- /* Linux x86_64 and OSX always align allocations to 16 bytes */
- #elif !defined(__amd64__) && !defined(__APPLE__) && !defined(_AIX)
- #define HAVE_MEMALIGN
- #include <malloc.h>
- #endif
#endif
#define opj_aligned_malloc(size) malloc(size)