July 15, 2026
Compiler tea: rules got wrapped
Bootstrapping GDC with DMD
A tiny workaround just embarrassed the rulebook and commenters are loving the chaos
TLDR: A FreeBSD developer showed that a compiler supposedly needing to build itself can actually be jump-started with a different one and a tiny workaround script. Commenters loved the clever shortcut, with the big mood being equal parts relief, curiosity, and “wait, it was that simple?”
A delightfully nerdy little rebellion just hit the programming crowd: one developer on FreeBSD figured out how to build GDC, a compiler the official docs basically say should be built using itself, by sneaking in DMD, another D-language compiler, with a homemade wrapper script. In plain English: the instructions said, “you need this tool to make this tool,” and the community reaction was basically, “well… apparently not.” That tiny act of rule-breaking is the real popcorn moment here.
The loudest reaction wasn’t outrage, but a kind of thrilled, slightly smug excitement. One commenter admitted this exact mismatch between different compilers had been a headache before, then had a mini epiphany in public: why not just wrap it? That gave the whole thread a scrappy hacker-energy vibe, like someone had broken into a locked room by noticing the window was open all along. Another user kept it short and sweet with the digital equivalent of a champagne toast: “Great news.”
The drama is subtle but juicy: this post quietly challenges the official documentation and suggests the supposed limitation may be more convention than law. Even the “hacky” bits, like faking a dependency file with a single newline, felt less scandalous and more chef’s kiss ingenious to the crowd likely reading it. There weren’t huge flame wars here, but there was that irresistible comment-section mood: part admiration, part “why didn’t anyone try the obvious thing sooner?”, and part gleeful enjoyment of a technical myth getting dunked on.
Key Points
- •The article describes bootstrapping GDC on FreeBSD using DMD because FreeBSD lacks a packaged GDC compiler.
- •GCC documentation says GDC requires an existing GDC and libphobos, but the article argues that only enough tooling to build stage1 GDC is necessary.
- •The author created gdc-wrapper to translate GDC-style compiler flags into DMD-compatible flags during the build.
- •The wrapper handles or ignores several flags, including a minimal workaround for dependency file options `-MF` and `-MT`.
- •The author reports successfully building GDC 15.2.0 and GDC 16.1.0 on FreeBSD 15 using FreeBSD x86_64 DMD 2.112.0 binaries.