#1149144 libc++-23-dev-wasm32: please provide both EH and non-EH variants

#1149144#5
Date:
2026-09-27 12:35:15 UTC
From:
To:
Dear Maintainer,

* What led up to the situation?

Since LLVM 23.1.0, Clang supports separate C++ standard library
variants for WebAssembly with and without exception handling. [1][2]

[1] [WebAssembly] Clang support for exception-based lookup paths -
#185775#185775 https://github.com/llvm/llvm-project/pull/185775
[2] [WebAssembly] Move __cpp_exception to libunwind
https://github.com/llvm/llvm-project/pull/185770

The Clang driver selects the appropriate variant depending on whether
-fwasm-exceptions is specified.

Currently, however, libc++-23-dev-wasm32 is built with:

  -DLIBCXX_ENABLE_EXCEPTIONS:BOOL=OFF
  -DLIBCXXABI_ENABLE_EXCEPTIONS:BOOL=OFF
  -DLIBCXXABI_USE_LLVM_UNWINDER:BOOL=OFF


As a result, the Debian WASM libc++ package provides only
the non-exception-enabled variant.

To make use of the exception-based lookup paths provided by Clang,
both the exception-enabled (EH) and non-exception-enabled (non EH)
variants of libc++ and libc++abi need to be built and installed in the
locations expected by the Clang WebAssembly driver.

* What was the outcome of this action?

When -fwasm-exceptions is enabled, the Clang driver is already able to
select the exception-enabled C++ standard library variant; otherwise it
selects the non-exception-enabled variant.

However, Debian currently does not provide the exception-enabled variant
in libc++-23-dev-wasm32, so C++ applications using WebAssembly exception
handling cannot use the corresponding libc++ runtime from the Debian
package.

Please consider providing both variants in the WASM libc++/libc++abi
packages.

Best Regards,