diff --git a/docs/wasmCompile.md b/docs/wasmCompile.md index 228cb2d..980ae06 100644 --- a/docs/wasmCompile.md +++ b/docs/wasmCompile.md @@ -5,7 +5,7 @@ - `--sysroot` specifying the stand library path ## Modify stubs.h -Modify the file `stubs.h` located in `lind-wasm/glibc/target/include/gnu` to +Modify the file `stubs.h` located in `/home/lind-wasm/glibc/target/include/gnu` to ``` /* This file is automatically generated. @@ -24,6 +24,19 @@ Modify the file `stubs.h` located in `lind-wasm/glibc/target/include/gnu` to #endif ``` +After modifying `stubs.h` remember to run `gen_sysroot.sh` again + +``` +cd /home/lind-wasm/glibc +./gen_sysroot.sh +``` + +Then we cd to lind-wasm-tests for testing + +``` +cd /home/lind-wasm/lind-wasm-tests +``` + ## Compile C to wasm If you don't need to use glibc, modify `add.c` to the c file you want to compile and `add.wasm` is the wasm file you get(you can modify add to the name you want). Modify `/home/clang+llvm-16.0.4-x86_64-linux-gnu-ubuntu-22.04/bin/clang` to you compiler's path