GnuChanIDE + GCL — a single language with Python and Lua embedded.
The idea is simple: I love Lua and Python, but I also want my own language. So I take them all. GCL is the main language; Python 3.14 and Lua 5.4.7 are its native parts. raylib is our shared library for games and graphics.
Think of GCL as a fridge. Inside there are tons of things: Python 3.14, Lua 5.4.7, raylib, packages installed via pip, and GCL's own standard library. You don't write Python code inside .gcsf files; GCL is not a shell that runs python script.py. Here is how it works:
- Python and Lua are GCL's capabilities. GCL code calls them whenever it wants.
gcl -pyrun script.pyandgcl -luarun script.luaare quick-run shortcuts.- The LSP scans the entire fridge: stdlib, site-packages, C extension modules, import chains. It knows everything inside the IDE.
┌─────────────────────────────────────────────┐
│ GCL (the fridge) │
│ │
│ Python 3.14 Lua 5.4.7 raylib │
│ (pyLibrary) (lua.gcDL) (+ pyd) │
│ + stdlib + stdlib │
│ + site-packages + luaLibrary │
│ + C extensions │
│ │
│ GCL language ── native capabilities │
└───────────────────┬─────────────────────────┘
│
▼
GnuChanIDE + gcl-LSP
(full fridge scan: imports, stdlib,
site-packages, C extensions)
With GCL you can write both low-level (C-like) and high-level (Python, Lua) code. Games, graphics, tools, automation... whatever you want. Here are a few modes of use:
| Mode | What does it do? |
|---|---|
gcl -run file.gcsf |
Runs GCL interpretively (JIT after the first 1000 calls) |
gcl -pyrun script.py |
Python quick-run shortcut |
gcl -luarun script.lua |
Lua quick-run shortcut |
gcl -ide [file] |
Launches the raylib-based GnuChanIDE |
gcl -lsp [workspace_dir] |
Starts the JSON-RPC LSP server |
gcl -build <project.gcdata> -o <dir> |
Builds a project into a .gcbundle |
gcl -new <project_name> [--lua/--python] |
Creates a new project skeleton |
gcl build <module> |
Builds a standard library module (e.g. Math) |
Build is a single command:
python language/makefile.py
This command, in order: downloads Lua, Raylib, Raygui, Python 3.14 and FreeFont under _temp/ if missing, embeds FreeMono.ttf as a C byte array (embed_freemono.c), compiles gcl.exe, then produces the Math, Stdio, Lua, LuaRaylib, Python modules as .gcdl and bundles the examples/Demo project. Output lands under language/build/<os>/.
GCL Source ──► .gclib/extern ──► .gcsf/extern ──► main.gcsf
│
▼
SharedPipeline ──► FastIR
src/
├── FastIR/
└── SharedPipeline/
├── Linker/
├── Lexer/
├── Parser/
├── Semantic/
├── TypeChecker/
├── Memory/
├── GarbageCollector/
├── AST/
├── Diagnostics/
├── Ir/
└── Common/
In the actual code, under language/src/ you will find:
shared_pipeline/— lexer, parser, AST, IR, typecheck, runner, errorlinker/— include, lib, native (math, stdio, embed)embed/— Lua, Python, raylib embeddinglsp/— JSON-RPC LSP serveride/— the raylib-based GnuChanIDEinclude/— all headers
Program
│
┌────────────┼─────────────┐
│ │ │
Stack Heap Static Data
│ │
│ ┌─────┼─────┐
│ │ │ │
Local Arena Pool Custom
Everything is checked: OOM + null + bounds + overflow.
build/windows/
├─ gcl.exe <- GCL compiler driver (hub) — runs interpreter, LSP, IDE, builds
├─ ide.gcsettings <- IDE settings (theme, font, workspace, effects)
├─ Library/
│ ├─ Math.gcdl <- GCL math standard library
│ ├─ Math_Ref.gclib <- math library reference
│ ├─ Stdio.gcdl <- GCL stdio standard library
│ ├─ Stdio_Ref.gclib <- stdio library reference
│ └─ EmbedSystem/
│ ├─ Lua.gcdl <- Lua 5.4.7 embed
│ ├─ LuaRaylib.gcdl <- Lua raylib binding
│ └─ Python.gcdl <- Python 3.14 embed
├─ Runtime/
│ └─ Python/ <- full Python 3.14 runtime bundle
│ ├─ python314.dll
│ ├─ Lib/ <- Python stdlib
│ │ └─ site-packages/ <- pip-installed packages (e.g. pip, requests)
│ ├─ DLLs/ <- Python extension DLLs
│ ├─ include/ <- Python headers
│ └─ Scripts/ <- Python scripts (pip, etc.)
├─ Assets/
│ └─ FreeMono.ttf <- embedded monospace font
└─ examples/
└─ Demo/ <- sample project bundle
├─ Demo.gcbundle
└─ Demo.exe
A raylib-based, self-contained development environment. You write, edit, and run code. It includes LSP integration — autocomplete, hover info, go-to-definition, and signature help. Editor + LSP + embedded Python/Lua runtime all together.
The IDE's syntax highlighter is language-aware:
.pyfiles recognize Python keywords,def/classnames,self/cls,__init__-style dunder methods, triple-quoted strings, and#comments..luafiles recognize Lua keywords,functionnames, and--comments..gcsf/.gclfiles use GCL keywords.
Colors follow the dark purple theme. The Build dialog lets you choose Debug or Release — the selected mode is highlighted, and the build output is placed in a debug/ or release/ subdirectory so the two modes stay separate.
Inside book/ there is an interactive textbook written in HTML + CSS + vanilla JS. The content covers GCL, Lua and Python lessons; fully in Turkish and English. 38 lessons:
- Introduction: Welcome
- GCL (12): Intro, Variables/Types, Operators, Control Flow, Functions, Arrays/Pointer, Pointer-Array Relationship, Struct/Enum, Recursion, File I/O, Modules/Preprocessor, Embed, Example Project
- Lua (11): Intro, Variables/Types, Operators, Tables, Table Library, Control Flow, Functions/Closure, String Library, Metatables, Iterators, pcall, Modules/require, Raylib
- Python (14): Intro, Variables/Types, Operators, Control Flow, Lists, Dicts/Sets, Functions, Modules/import, OOP, File Handling, JSON, Error Handling, Decorators, Generators, Raylib
Book features: live search (Ctrl+K or /), keyboard shortcuts (←/→), the open/closed state of the sidebar persists in memory, syntax highlighting, code-copy buttons, and a progress bar. The design follows a purple-only palette with dark background/light text. Just open book/index.html in your browser.
Under language/examples/Demo/ there is a sample project. The main.gcsf file contains GCL code; the scripts/ folder holds main.py and main.lua. The project.gcdata file defines the project configuration. You can package this project into a single .gcbundle with gcl -build, or run it directly.
gnuchanos.md for the complete architectural reference.