@Gaelan For your last point, nix on Lambda, there a minimal PoC here:
Contribute to tomberek/lambdanix development by creating an account on GitHub.
LambdaNix
I have a POC of running Nix in AWS Lambda: GitHub - tomberek/lambdanix
It involves several hacks and patching/hacking of libraries, but it has basic minimal function. Given all the inputs for a simple derivation, it can then go build it.
Biggest hurdles
lack of root/chroot: libfakechroot.so
lack of pseudoterminal in Lambda environment, Nix really wants to have one, LD_PRELOAD’ed past this with some custom horrible code.
No access to /nix/store : use nixrewrite (GitHub - timjrd/nix…
The initial impetus was to use this with Stanford’s gg. It’s all ugly and a massive hack and is probably out of date by now, but it may help you in some way.
For alternative toolchains, i’m sure the ALLVM [ALLVM Research Project | LLVM All the Things! - University of Illinois at Urbana-Champaign ] effort would love to make progress.