Files
MINGW-packages/mingw-w64-embree3/002-arm64-no-mm-malloc.patch
Christoph Reiter 0536cf4162 embree3: fix build error with clangarm64 due to missing _mm_malloc
It was removed in mingw-w64/mingw-w64@6affcc5d15
Let's just used the default Windows API for this in all cases.
2023-08-05 12:24:38 +02:00

20 lines
623 B
Diff

--- embree-3.13.5/common/sys/alloc.cpp.orig 2023-08-05 12:22:20.363254500 +0200
+++ embree-3.13.5/common/sys/alloc.cpp 2023-08-05 12:22:53.386727300 +0200
@@ -9,7 +9,15 @@
////////////////////////////////////////////////////////////////////////////////
/// All Platforms
////////////////////////////////////////////////////////////////////////////////
-
+
+#ifdef _WIN32
+#define WIN32_LEAN_AND_MEAN
+#include <windows.h>
+
+#define _mm_malloc(size, alignment) _aligned_malloc(size, alignment)
+#define _mm_free(ptr) _aligned_free(ptr)
+#endif
+
namespace embree
{
void* alignedMalloc(size_t size, size_t align)