Skip to content
DiasFranciscoA edited this page Feb 25, 2026 · 4 revisions

extgen - GameMaker Extension Code Generator

Welcome to extgen, a schema-driven code generator for GameMaker native extensions.

From a single GMIDL input file, extgen can generate:

  • GML bindings (plus optional runtime helpers)
  • Native glue code for multiple platforms (Android / iOS / tvOS / consoles)
  • A complete CMake project + presets to build your extension
  • Optional docs output for downstream tooling

The goal: one source of truth β†’ repeatable, consistent extension output.


πŸš€ Quick Start

1) Initialize a project folder

extgen --init ./my-extension

This creates:

  • config.json
  • extgen.schema.json

2) Edit config.json

Set:

  • your GMIDL input (input)
  • your output root (root)
  • desired targets (targets.*)
  • build emission (build.emitCmake)

3) Generate

extgen --config ./my-extension/config.json

πŸ“š Wiki Navigation

βœ… Getting Started

  • User Manual - how to run extgen, configure targets, and understand all schema options
  • GMIDL Introduction - how to start declaring your extension functions
  • Implementation Workflow - recommended / suggested workflows for the various targets

🧰 Development

  • Architecture / Developer Docs - project structure, emitters, pipeline, where to contribute
  • Build extgen - build the tool from CLI, Visual Studio, or VS Code

🧭 Key Concepts

βœ… Schema-driven configuration

Your config.json is validated via extgen.schema.json. If the schema validates, extgen should run reliably.

🎯 Target-driven output

extgen is target-driven, not β€œlanguage toggles driven”.

Enabling a target (like Windows or iOS) automatically implies the correct underlying emitters (like C++ where required).

πŸ§ͺ Profiles

Use profiles to control what gets emitted:

  • Full β†’ bindings + native glue + build system
  • BindingsOnly β†’ only bindings (no native/build output)
  • BuildOnly β†’ only build system (CMake / presets)

πŸ›Ÿ Need Help?

  • If you're a user: start with User Manual
  • If you're contributing: start with Architecture / Developer Docs
  • If you’re building the tool: go to Build extgen

✨ Contributing

extgen is designed to be extended:

  • new platforms
  • new emitters
  • improved templates
  • better docs and examples

If you want to contribute, check Architecture / Developer Docs and follow the repository contribution guidelines.

Happy generating πŸš€