How to build a CMake project using Cheerp
CMake projects can be compiled with Cheerp by passing a single additional command-line flag to
A CMake toolchain file is provided at
$CHEERP/share/cmake/Modules/CheerpToolchain.cmake, where the
CHEERP environment variable is set to the path of your Cheerp installation.
- On Linux:
- On macOS:
- On Windows:
Then pass the toolchain file when configuring the project.
Compiling to WebAssembly
To compile with
-target cheerp-wasm, use
See this example repository for a working example.