Build ligo on Macos(intel), Linux and Windows and bundle into NPM tarball
Motivation and Context
We want a single command that would work on Windows, Linux and MacOS. NPM provides a way to do this if the binaries for the three platforms are bundled and installed correctly. Esy provides a way to wrap the binaries in a an environment that contains all the runtime dependencies.
Description
This MR makes sure Ligo builds on MacOS (both arm64 and x86_64). It adds a CI job that creates macos binary artifacts that can be bundled in alongside Linux and Windows. It updates esy manifest, lock files and CI script to build ligo on Windows again.
Summary
- Path shortening by renaming modules - dune creates very long paths to create intermediate/temporary files. This is problematic on Windows.
- Removing core_unix that doesn't build on Windows
- Patching Octez+lima for Windows
Types of changes
-
Bug fix (non-breaking change which fixes an issue) -
New feature (non-breaking change which adds functionality) -
Breaking change (fix or feature that would cause existing functionality to not work as expected) -
Performance improvement (non-breaking change that improves performance) -
None (change with no changelog) -
Added
Changelog
Users can now install LIGO via NPM. npm i -g ligolang
will install the Ligo compiler on Windows, Linux and MacOS (intel).
https://www.npmjs.com/package/ligolang
Also adds a GUI installer for Windows. Can be downloaded from here
Checklist:
-
Changelog description has been added (if appropriate).