esy-issues
esy-issues copied to clipboard
Add `esy.sandboxEnv`
Add new key in package.json
called esy.sandboxEnv
.
Motivation:
- Set
OCAMLRUNPARAM=b
so we can have stack traces. - Override C compiler (e.g. choose between
clang
orgcc
)
It should have the same format as esy.exportedEnv
but the mechanics should be the following:
- Only top level package's
esy.sandboxEnv
is considered. - Env vars in
esy.sandboxEnv
should be propagated to all package's builds. - Make sure those env vars participate in build cache key.
See https://github.com/jordwalke/esy/blob/9eed98f8024c3a64502387f021db7fe10ed0680a/lib/Sandbox.js#L189-L205 for the existing sandox env config. The proposed esy.sandboxEnv
key is a mechanism to override this environment.