Compiletest doesn't pass environment variables to emscripten tests
Compiletest sometimes passes environment variables when building the Command object. However in the case of emscripten, these values get passed to node instead of the program itself.
node can't propagate env vars to the javascript code, since javascript has no concept of an environment variable. It is possible to pass environment variables to the "emscripten runtime", but that must be done by manually adding some JS code in the header of the file.
For the moment the tests that rely on env vars are ignored and point to this issue.
node can't propagate env vars to the javascript code, since javascript has no concept of an environment variable.
Not sure what this means. Node.js scripts surely have access to environment variables via
process.env.Ingvar Stepanyan at 2017-02-13 11:19:00
The problem is that the Rust code doesn't retreive environment variables with
process.envbut with thegetenvfunction provided by Emscripten.If emscripten were to call
process.envto fill environment variables then it would work, but I'm not sure it does. I follow the path until here and here but I can't find what calls__libc_start_mainordynlink.Pierre Krieger at 2017-02-13 11:58:53
@tomaka Sounds like https://github.com/kripken/emscripten/issues/3915 (which is to be fixed in https://github.com/kripken/emscripten/pull/3948).
Ingvar Stepanyan at 2017-02-13 12:07:49