Fix sample ref-types/wasm-c-api build error with wat2wasm low version (#1702)
Fix build error in sample ref-types and wasm-c-api caused by the version of wat2wasm: refine makefile to auto detect the wat2wasm version and add the compile flag accordingly.
This commit is contained in:
@ -3,7 +3,7 @@
|
||||
|
||||
(module
|
||||
(func $get_pairs (import "" "get_pairs") (result i32))
|
||||
(func $log (import"" "log") (param i32 i32))
|
||||
(func $log (import "" "log") (param i32 i32))
|
||||
|
||||
(func $on_start (export "on_start")
|
||||
(call $log (i32.const 0) (i32.const 9))
|
||||
@ -29,4 +29,4 @@
|
||||
(data (i32.const 9) "on_stop")
|
||||
(data (i32.const 17) "malloc")
|
||||
(data (i32.const 24) "free")
|
||||
)
|
||||
)
|
||||
|
||||
@ -1,6 +1,6 @@
|
||||
(module
|
||||
(func (export "func") (param i32 f64 f32) (result i32) (unreachable))
|
||||
(global (export "global") f64 (f64.const 0))
|
||||
(table (export "table") 0 50 anyfunc)
|
||||
(table (export "table") 0 50 funcref)
|
||||
(memory (export "memory") 1)
|
||||
)
|
||||
|
||||
Reference in New Issue
Block a user