ligo/nix
2020-05-25 18:47:40 +03:00
..
default.nix Add nix as a build system 2020-04-29 19:40:04 +01:00
docker.nix Fix webide docker container 2020-05-25 18:47:40 +03:00
ligo-editor.nix Add documentation for nix expressions 2020-05-21 18:08:25 +03:00
ligo-website.nix Update install documentation to reflect packaging updates 2020-05-21 18:56:44 +03:00
mac-overlay.nix Add nix as a build system 2020-04-29 19:40:04 +01:00
nodejs-overlay.nix Add documentation for nix expressions 2020-05-21 18:08:25 +03:00
ocaml-overlay.nix Add documentation for nix expressions 2020-05-21 18:08:25 +03:00
packageDeb.nix Add documentation for nix expressions 2020-05-21 18:08:25 +03:00
pkgs.nix Fix webide docker container 2020-05-25 18:47:40 +03:00
README.md Clarify the nix docs by pointing out the location of build results 2020-05-21 18:09:33 +03:00
sources.json Update nix-npm-buildpackage 2020-05-21 18:08:25 +03:00
sources.nix Add nix as a build system 2020-04-29 19:40:04 +01:00
static-overlay.nix Add documentation for nix expressions 2020-05-21 18:08:25 +03:00
static.patch Add documentation for nix expressions 2020-05-21 18:08:25 +03:00

Nix expressions for building LIGO

Nix is a declarative package manager. Get it here: https://nixos.org/nix

These expressions are used on CI to reproducibly build the LIGO compiler, as well as WebIDE and https://ligolang.org .

If you wish to build it yourself, do nix build -f. $thing, where $thing is

  • ligo: executables, libraries, documentation, coverage reports
  • ligo-bin: a dynamically linked binary (Linux, Mac)
  • ligo-static: a statically linked binary (Linux only)
  • ligo-doc: documentation generated by odoc
  • ligo-editor: WebIDE, it can be started with result/bin/ligo-editor
  • ligo-website: the website, website root is result
  • ligo-docker: a docker image with LIGO binaries
  • ligo-editor-docker: a docker image with webide
  • ligo-deb: debian package with static binaries

The output of nix build can be found in result directory.

Quick maintenance guide

  • opam-repository and tezos-opam-repository are pinned. To update them when required, run niv update (you can get niv with nix shell 'nixpkgs#niv')
  • ocaml version is pinned in ocaml-overlay.nix. If you want to update it, go there and change the version.
  • If something fails, nix repl pkgs.nix can be very useful to investigate it.

Known caveats

  • This is not a nix flake. This will never be a flake if we want to keep this low-maintenance, because of the way opam sources are defined. Sometimes, the checksum is omitted there, so we have to use fetchTarball without the checksum, which won't work in restricted mode (which is required for flakes). The only solution would be to generate nix expressions for opam-repository separately, but it means a manual step in the process (and it's also impossible to make this work as a flake).
  • For the same reason as above, evaluation can take a while because we need to download all the sources every tarball-ttl seconds. This can be mitigated by setting tarball-ttl to a high value.