🚀 ForgeZero v1.9.0 — The 'Architect' Update: LSP Integration, Cross-Compilation & Industrial-Grade Reliability
Source: Dev.to
If you’ve been sleeping on ForgeZero (fz) — the zero‑config C build tool that actually respects your time — v1.9.0 just dropped and it’s a proper glow‑up. We’re talking IDE superpowers, native cross‑compilation, a critical bug squash, and enough test coverage to make your QA lead weep with joy. Let’s break it down. 🧵
1. LSP & IDE Support — Your Editor Finally Gets It
fz -compile-commands
One flag. That’s all it takes to spit out a compile_commands.json — the Compilation Database that every serious editor lives and breathes.
What this means in practice
- Neovim + clangd – full autocomplete, go‑to‑definition, find‑references. Everything just works™
- VSCode + clang – same story, zero manual config
- Any LSP client – if it reads
compile_commands.json, it’s happy
fz went from “fast build runner” to a legit professional dev environment with this single addition. Your IDE will finally stop lying to you about missing includes.
2. Cross‑Compilation — Build for ARM from Your x86 Couch
Embedded devs, this one’s for you. fz now ships with full cross‑compilation support out of the box:
fz -target arm-linux-gnuebihf
That’s it. No hunting for toolchain paths, no manual -CC= gymnastics. fz auto‑detects the correct prefixed compilers and linkers for your target triple.
Supported target examples
arm-linux-gnuebihf— ARMv7 hard‑float (Raspberry Pi and friends)- Any standard GNU cross‑compilation triple
3. Industrial Reliability — The Boring Part That Actually Matters
Linker Coverage
48 % → 60 %+
We added extensive linker tests, covering the darkest corners of the linking pipeline. Fewer “works on my machine” surprises in CI.
Critical Bug Fix: Object Name Collisions
Multi‑file projects were silently producing _.o collisions — files from different directories could stomp each other’s object files, leading to corrupted builds that were sometimes correct.
The fix: every object file now gets a unique name derived from its full source path.
Before: src/foo.c → _.o (collision risk)
After: src/foo.c → src_foo.o (unique, always)
No more _.o. No more collisions. Multi‑file projects build reliably, every time.
4. UX & Infrastructure — The QoL Stuff You’ll Actually Notice
Smart Self‑Update with Rollback
fz -update
Before: blew away your old binary and hoped for the best.
Now: backs up the old version to /usr/local/bin/fz.old before installing the new one. Break something? Roll back in one move. Safe as it gets. 💊
Shell Mode Now Has Tests
The interactive shell (fz REPL mode) now has full test coverage for:
SplitCommandparsingCmdSethandlingCmdBuildexecution
Your in‑tool console is no longer running on vibes and prayers.
5. Strict Coding Standards — fz Teaches You to Write Clean C
ForgeZero now ships with sane‑by‑default compiler flags in all docs and JSON command configs:
-Wall -Wextra -Werror -Wpedantic -Wshadow -Wconversion
This isn’t gatekeeping — it’s a forcing function. If your code compiles cleanly with these flags, it’s genuinely clean code. fz has an opinion about code quality, and it’s the right one. Treat warnings as errors. Your future self will thank you.
TL;DR — What Shipped in v1.9.0
| Feature | What It Does |
|---|---|
-compile-commands | Generates compile_commands.json for LSP/IDE |
| Cross‑compilation | -target — auto‑detects toolchain |
| Object name fix | Unique .o names, no more multi‑file collisions |
| Linker coverage | 48 % → 60 %+ test coverage |
| Smart update | fz -update backs up old binary to fz.old |
| Shell tests | SplitCommand, CmdSet, CmdBuild are tested |
| Default flags | -Wall -Wextra -Werror -Wpedantic -Wshadow -Wconversion |
What’s Next?
The “Architect” name wasn’t chosen lightly. v1.9.0 lays the foundation for fz to become the go‑to build tool for serious C projects — from single‑file scripts to multi‑target embedded systems.
Got feedback? Ran into an edge case? Drop it in the comments or open an issue. We read everything. 👇
Built with fz. Compiled cleanly. No warnings.