llvm-wasm
llvm-wasm copied to clipboard
Could you please provide guides for building `clang` to wasm?
Hello! I'm interested in your project (for detailed guide of building LLVM on WASM). I noticed that the GitHub Page is using clang-wasm branch which includes a clang.wasm, but the README only shows how to build llc / lld.
In detail, I'm trying to build clangd language server and face some issues on finding Standard C/C++ library headers in Emscripten FS. Could you tell me how to embed (and how to find) those C/C++ headers to WASM? Seems that the original README just embedding lib folder is not a correct approach for clang.
Thank you!
Hi! Yes, the README needs some updating - it was initially only for llc & lld, but the demo page uses clang instead of llc. IIRC clang was compiled as part of building llc & lld so I only had to export clang.* - will check again.
I haven't compiled clangd though, that'd be interesting to try!