I recently succeeded in compiling & deploying a C++ application that includes the standard library AND an external library, the nlohmann/json library.
For this, I am using a patched wasi-sdk compiler, which provides the clang++ compiler and the standard library, plus a home-grown IC API to get messages in/out via Candid.
The patched wasi-sdk is already open source, you can find it here.
But the IC-API, which I call
icpp is not yet. It needs a bit more work. I had applied for a small grant to open source that IC API, because I think it can be a good starting point for full fledged C++ support.
icpp API was reviewed by @roman-kashitsyn, and his feedback was that my approach is not ideal/not scalable, and he proposed an alternative approach to build a C++ SDK instead of an API.
I like to explore both approaches together with others that are interested in this topic, and potentially team up to apply for a grant together.
Hope to see some of you there!