diff --git a/main.c b/main.c index bd20eab..72f6589 100644 --- a/main.c +++ b/main.c @@ -27,7 +27,7 @@ uint8_t *read_file(const char *filename, uint32_t *fsize) { void test_wrt() { uint32_t buf_size; - uint8_t *buf = read_file("wasm_sample.wasm", &buf_size); + uint8_t *buf = read_file("example.wasm", &buf_size); WRTContext context; wrt_platform_init(&context, malloc, free); diff --git a/tests/.gitignore b/tests/.gitignore new file mode 100644 index 0000000..7447f89 --- /dev/null +++ b/tests/.gitignore @@ -0,0 +1 @@ +/bin \ No newline at end of file diff --git a/tests/lib/build.sh b/tests/lib/build.sh new file mode 100755 index 0000000..dce6e29 --- /dev/null +++ b/tests/lib/build.sh @@ -0,0 +1,3 @@ +#!/usr/bin/env bash + +clang++ -O3 -shared -o ../bin/SimpleLib.so SimpleLib.cpp diff --git a/tests/wasm/build.sh b/tests/wasm/build.sh index 835f6a4..10c0d60 100755 --- a/tests/wasm/build.sh +++ b/tests/wasm/build.sh @@ -1,8 +1,8 @@ #!/usr/bin/env bash WAMR_DIR=../../wasm-micro-runtime -PROG_SRCS=sample.c -BIN_FILE=wasm_sample.wasm +PROG_SRCS=example.c +BIN_FILE=../bin/example.wasm clang \ --target=wasm32 -O3 -z stack-size=4096 -Wl,--initial-memory=65536 \ diff --git a/tests/wasm/sample.c b/tests/wasm/example.c similarity index 100% rename from tests/wasm/sample.c rename to tests/wasm/example.c