Code generation tool for the Hokku engine. Parses C++ headers using libclang and emits reflection, enum-to-string, and HashLink binding code via inja templates.
See hqcodegen_demoproject for a working integration example, including CMake wiring, tests, and HashLink bindings.
- Python 3.*
- Conan 2.* (
pip install conan) - CMake 3.28+
- LLVM/Clang 15-17 (libclang)
- On Windows (MSVC):
- MSVC v143 - VS 2022 C++ x64/x86 build tools
conan install . -of Conan -b missing -s build_type=Release -c tools.cmake.cmaketoolchain:generator=Ninja
Conan\conanbuild.bat
cmake --preset CodeGen -DLIBCLANG_ROOT=<path-to-clang>
cmake --build Build
cmake --install Build
The executable and templates are installed to Install/CodeGen/.
Install/CodeGen/HQCodeGen.exe \
--input="<source-dir>" \
--output="<output-dir>" \
--template_path="Install/CodeGen" \
--plugin_name="<ModuleName>"See Examples.md for more details.