Building from source

GodotXterm uses a Justfile to automate the build process. This handles compiling libuv, godot-cpp, and the GodotXterm native library.

Dependencies

  • Git (to clone git submodules)

  • Just (command runner)

  • SCons (build system for Godot native extensions)

  • CMake (to build libuv)

  • A C/C++ compiler (gcc, clang, MSVC, etc.)

Quick start

# Build native extension (debug)
just build

# Build all targets including JavaScript
just build-all

# Clean build artifacts
just clean

Build targets

The build system supports different targets via the TARGET environment variable:

# Debug build (default)
just build

# Release build
TARGET=release just build

Platform-specific builds

JavaScript/Web

Building for web requires Docker:

just build-javascript

This uses a Docker container to cross-compile to WebAssembly.

Testing your build

After building, test your changes:

# Run all tests
just test

# Run specific test types
just test unit
just test integration
just test visual

Legacy build script

An older build.sh script exists in addons/godot_xterm/native/ but is deprecated. Use the Justfile commands above for the current build process.