|
|
@@ -129,8 +129,12 @@ iwasm_main(void *arg1, void *arg2, void *arg3)
|
|
|
init_args.mem_alloc_type = Alloc_With_Pool;
|
|
|
init_args.mem_alloc_option.pool.heap_buf = global_heap_buf;
|
|
|
init_args.mem_alloc_option.pool.heap_size = sizeof(global_heap_buf);
|
|
|
+#elif (defined(CONFIG_COMMON_LIBC_MALLOC) \
|
|
|
+ && CONFIG_COMMON_LIBC_MALLOC_ARENA_SIZE != 0) \
|
|
|
+ || defined(CONFIG_NEWLIB_LIBC)
|
|
|
+ init_args.mem_alloc_type = Alloc_With_System_Allocator;
|
|
|
#else
|
|
|
-#error Another memory allocation scheme than global heap pool is not implemented yet for Zephyr.
|
|
|
+#error "memory allocation scheme is not defined."
|
|
|
#endif
|
|
|
|
|
|
/* initialize runtime environment */
|