summaryrefslogtreecommitdiffstats
path: root/fluent-bit/lib/wasm-micro-runtime-WAMR-1.2.2/core/iwasm/fast-jit/asmjit_sgx_patch.diff
blob: 465b9de616e7817f02a0d6f2b9a9416b4f93da04 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
diff --git a/src/asmjit/core/cpuinfo.cpp b/src/asmjit/core/cpuinfo.cpp
index 7bf7407..ae2160b 100644
--- a/src/asmjit/core/cpuinfo.cpp
+++ b/src/asmjit/core/cpuinfo.cpp
@@ -9,13 +9,13 @@
 
 #if !defined(_WIN32)
   #include <errno.h>
-  #include <sys/utsname.h>
+  //#include <sys/utsname.h>
   #include <unistd.h>
 #endif
 
 // Required by `getauxval()` on Linux.
 #if defined(__linux__)
-  #include <sys/auxv.h>
+  //#include <sys/auxv.h>
 #endif
 
 //! Required to detect CPU and features on Apple platforms.
diff --git a/src/asmjit/core/globals.cpp b/src/asmjit/core/globals.cpp
index 2bbd0c0..e6b69e5 100644
--- a/src/asmjit/core/globals.cpp
+++ b/src/asmjit/core/globals.cpp
@@ -105,6 +105,8 @@ ASMJIT_FAVOR_SIZE const char* DebugUtils::errorAsString(Error err) noexcept {
 #endif
 }
 
+extern "C" int os_printf(const char *message, ...);
+
 // DebugUtils - Debug Output
 // =========================
 
@@ -112,7 +114,7 @@ ASMJIT_FAVOR_SIZE void DebugUtils::debugOutput(const char* str) noexcept {
 #if defined(_WIN32)
   ::OutputDebugStringA(str);
 #else
-  ::fputs(str, stderr);
+  os_printf(str);
 #endif
 }