[Nix-dev] Using Nix as the preferred package manager for a new language
stewart mackenzie
setori88 at gmail.com
Tue Feb 9 18:32:01 CET 2016
We're doing almost exactly this at github.com/fractalide/fractalide.
Fractalide is a Flow-based programming language implemented in Rust
We're also facing many of the issues you are :-)
Rust has a slow compilation, so nix's lazy evaluation means (after a
long initial build of every component) we only compile the needed
dependency chain after a change thereafter. Secondly we've have a
component_lookup (which maps a common name such as
'maths_boolean_nand' to /nix/store/<hash>-maths_boolean_nand) of which
every single component is dependent, so we have to build everything
first time round.
The only way around this I see: is a conservative language extension
to hopefully make fbp expressive enough to be able directory walks. ie
similar to ./. in nix.
Then...
The path I'd like to go is that of guix and implement our own nix in
fbp (bootstrapping with nix) thus we can have a coordination layer
over rust flow based programming components and components wrapped
around other non-rust projects such as postgres etc. This would be
activated as simple as `postgres_instance_1(postgres)`.
Say for example:
'path:(path="${fractalide_docs}")' -> www_dir server(web_server)
'domain_port:(domainPort="localhost:8080")' -> domain_port server()
Normally the above wouldn't be committed into the fractalide repo but
having a "fractalnix" means ${fractalide_docs} could be evaluated. I'm
unsure of the details as yet.
Anyway keen to see this conversation take off!
/sjm
On Wed, Feb 10, 2016 at 12:40 AM, <cds at corbinsimpson.com> wrote:
> We're seeking any advice on how to make this situation better. As far as
> we can tell, nobody else has tried to make Nix their first-class preferred
> package management solution for their language, so we are blazing trails
> here.
More information about the nix-dev
mailing list