Docs/Getting Started/Installation
Installation
Install Fid on Windows with the installer, or build it from source on Linux and macOS.
~3 min read
On this page
Windows: the installer (v0.8.0-unstable)
Download Fides-Setup-0.8.0.exe →
6.6 MB. It installs the compiler, ark (packages), scribe (docs), veil (coverage), the standard library and examples to Program Files\Fides, adds them to PATH and associates .fd files. Uninstall from Add/Remove Programs.
v0.8.0 is an unstable prerelease of the self-hosted compiler, built on Nov 10: generics, @cfg, borrowed strings, safety checks, fid qualify, fid lint --perf, fid explain and full Unicode normalization are in. A v1.0.0 stable release is planned for December. The installed fid version prints fid 0.1.0: the version string was updated after this build. The release has no checksum file yet.
Linux and macOS: build from source
No prebuilt archive is published for Linux or macOS yet (the install.sh one-liner says so, prints these steps and stops). Linux x64 is supported; macOS is experimental and has not been run on a Mac. Building needs git, a Rust toolchain and a C compiler (gcc, clang or zig cc):
git clone https://github.com/pledgeandgrow/fid
cd fid
cargo build --release # fidesc, ark, scribe, veil
RELEASE=1 CC="zig cc" ./scripts/bootstrap.sh # fid, checked to rebuild itself identicallyIntegrity: install.sh downloads artifacts from GitHub Releases over TLS and verifies the SHA-256 checksum whenever the release publishes a SHA256SUMS manifest; a checksum mismatch aborts the install. No release publishes one yet, so the script warns and continues. On Windows, install.ps1 downloads the installer above and starts it.
The compiler lands in release/fid; add release/ and target/release/ to your PATH. Check it:
fid versionfidesc is the earlier compiler, written in Rust. It is frozen: it builds stage 1 of the bootstrap and runs the test suite, and gets no new features. The bootstrap builds fid three times and checks that stages 2 and 3 produce the same C, byte for byte.
Upgrade and uninstall
- Windows: to upgrade, run the newer installer; it replaces the previous version. To remove Fid, use Add/Remove Programs.
- From source:
git pull, then run the two build commands again. To remove it, delete the checkout and takerelease/andtarget/release/off your PATH.
Troubleshooting
| Symptom | Cause and fix |
|---|---|
| Windows shows “Windows protected your PC” | The installer is not code-signed yet. Choose “More info”, then “Run anyway”, after checking you downloaded it from the GitHub release. |
fid is not recognized after installing | PATH changes apply to new terminals. Close and reopen the terminal. |
fid ccompile or fid build cannot find a compiler | The C backend needs a C compiler. Install gcc, clang, zig or tcc, or set CC (for example CC="zig cc"). fid run and fid emit need none. |
| The standard library is not found | fid looks in $FID_HOME/stdlib, then beside the executable, then one folder up. Set FID_HOME, or keep stdlib/ next to fid. |
fid version prints fid 0.1.0 | Expected for the v0.8.0 installer; the version string was updated after that build. |
Still stuck? Open an issue with the command you ran and its full output.
Packages
Libraries are installed with ark:
ark init myproject
ark add mylib --git https://github.com/user/mylib
ark installSee the CLI Reference for every ark command.
Next steps
Head to the Quick Start to write and run your first program.