[llvm] Disable shared libraries when building with emscripten (PR #118262)

Chris B via llvm-commits llvm-commits at lists.llvm.org
Mon Jan 6 16:11:21 PST 2025


llvm-beanz wrote:

Seconding @MaskRay, if Emscripten doesn't support shared libraries we _could_ error when you pass options like `BUILD_SHARED_LIBS` or `LLVM_ENABLE_LLVM_DYLIB` which cause LLVM to generate shared libraries, but we definitely should not be changing AddLLVM to magically shut off the library types.

You might want to make a change to CMake to detect the Emscrpiten target and error out if the Emscripten toolchain doesn't support shared libraries, but that should be done in CMake not LLVM's build system.

https://github.com/llvm/llvm-project/pull/118262


More information about the llvm-commits mailing list