aboutsummaryrefslogtreecommitdiff
path: root/sysutils/fluent-bit/files/patch-src_wasm_CMakeLists.txt
blob: e173a8cabc6ac2fed160e8539486c8cd550d8186 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
--- src/wasm/CMakeLists.txt.orig	2023-03-08 22:58:52 UTC
+++ src/wasm/CMakeLists.txt
@@ -30,14 +30,14 @@ if (NOT DEFINED WAMR_BUILD_TARGET)
     set (WAMR_BUILD_TARGET "ARM")
   elseif (CMAKE_SYSTEM_PROCESSOR STREQUAL "riscv64")
     set (WAMR_BUILD_TARGET "RISCV64")
-  elseif (CMAKE_SIZEOF_VOID_P EQUAL 8)
+  elseif (CMAKE_SYSTEM_PROCESSOR MATCHES "^(amd|x86_)64")
     # Build as X86_64 by default in 64-bit platform
     set (WAMR_BUILD_TARGET "X86_64")
-  elseif (CMAKE_SIZEOF_VOID_P EQUAL 4)
+  elseif (CMAKE_SYSTEM_PROCESSOR MATCHES "^i.86")
     # Build as X86_32 by default in 32-bit platform
     set (WAMR_BUILD_TARGET "X86_32")
   else ()
-    message(SEND_ERROR "Unsupported build target platform!")
+    set(WAMR_BUILD_INVOKE_NATIVE_GENERAL 1)
   endif ()
 endif ()