diff --git a/core/shared/platform/zephyr/platform_internal.h b/core/shared/platform/zephyr/platform_internal.h index d5f0c80d81..134b5c2b5f 100644 --- a/core/shared/platform/zephyr/platform_internal.h +++ b/core/shared/platform/zephyr/platform_internal.h @@ -290,7 +290,9 @@ typedef struct timespec os_timespec; #define CLOCK_REALTIME 1 #endif +#ifndef CLOCK_MONOTONIC #define CLOCK_MONOTONIC 4 +#endif static inline int os_sched_yield(void) diff --git a/core/shared/platform/zephyr/zephyr_file.c b/core/shared/platform/zephyr/zephyr_file.c index 1f48bc010c..79b6756e3f 100644 --- a/core/shared/platform/zephyr/zephyr_file.c +++ b/core/shared/platform/zephyr/zephyr_file.c @@ -6,6 +6,7 @@ #include "platform_api_vmcore.h" #include "platform_api_extension.h" #include "libc_errno.h" +#include "bh_common.h" #include #include @@ -1195,4 +1196,4 @@ bool os_is_stderr_handle(os_file_handle handle) { return (handle == (os_file_handle)stderr); -} \ No newline at end of file +}