I am trying to create a derivation for
gleam, a statically typed language on the BEAM-VM.
The compiler itself is currently written in Rust while the stdlib is written in Gleam itself and compiled on demand for each project, traditionally managed through
rebar3, the same buildsystem used for
erlang as well.
My idea was to start by providing the compiler itself to
nixpkgs, such that the current BEAM-modules can be used to pull the stdlib from hex. But small steps first, the compiler needs to be available first.
But currently the compiler and the stdlib are in the same repository in sibling folders.
The root folder of the project contains a
Makefile and I hoped I could just use the default builder, but it fails because of missing permissions then.
But since the
install target basically is just doing
cargo install in a sub folder, I wanted to do a “sparse” checkout of the sources and just use
rustPlatform.buildRustPackage, but I can’t find a way to do so…