My solutions for Advent of FPGA 2025, written in OCaml using Hardcaml.
This project uses the oxcaml compiler and Jane Street's opam repository.
- opam 2.x
- System dependencies:
libgmp-dev,libffi-dev,pkg-config,zlib1g-dev
On Ubuntu/Debian:
sudo apt-get install libgmp-dev libffi-dev pkg-config zlib1g-dev- Add the oxcaml opam repository:
opam repo add ox https://github.com/oxcaml/opam-repository.git- Create a switch with the oxcaml compiler:
opam switch create . ocaml-variants.5.2.0+ox- Install dependencies:
opam install . --deps-onlydune builddune runtestFirst, populate inputs/. Make sure the file names are in the format day{DD}.txt. Then run dune exec bin/run_day{DD}.exe. Replace DD with your day.