ww: preserve original environment for directory tests
This commit is contained in:
@@ -305,6 +305,16 @@ the private run and install only after success. Compile-only, assembly-only,
|
||||
no-test, rejected, and build requests start no test process and therefore have
|
||||
no test-PATH state.
|
||||
|
||||
For a directory product, the rest of the child vector is a Go-like snapshot of
|
||||
the caller environment rather than the build-tool environment: the first
|
||||
case-sensitive occurrence of every normal `key=value` survives, later normal
|
||||
duplicates and raw empty entries do not, and nonempty malformed entries remain
|
||||
in order. Only the effective `PATH` and package `PWD` are then appended.
|
||||
Caller `LC_ALL`, `TMPDIR`, empty values, case-distinct keys, and arbitrary
|
||||
variables therefore reach dependency initialization and selected tests.
|
||||
Build-plan compiler, assembler, archiver, linker, and scratch environments keep
|
||||
their existing pinned locale and request-private temporary directory.
|
||||
|
||||
Every such product also receives an independently opened null device as fd 0.
|
||||
Caller terminal, pipe, and file bytes remain with the coordinator; serial and
|
||||
parallel products observe immediate EOF rather than consuming a shared input
|
||||
|
||||
Reference in New Issue
Block a user