[lit] Pass more environment variables through to child processes.
authorZachary Turner <zturner@google.com>
Tue, 27 Nov 2018 19:29:12 +0000 (19:29 +0000)
committerZachary Turner <zturner@google.com>
Tue, 27 Nov 2018 19:29:12 +0000 (19:29 +0000)
commitd37fa56a8ed6d25036e5c52ab64aa8c9ec4c2068
tree1674b9386e843f70115fd7c577dde910277088ba
parentffba54493f5d56dcf3e43d1f0bb4584b7bb721e1
[lit] Pass more environment variables through to child processes.

This arose when I was trying to have a substitution which invoked a
python script P, and that python script tried to invoke clang-cl (or
even cl). Since we invoke P with a custom environment, it doesn't
inherit the environment of the parent, and then when we go to invoke
clang-cl, it's unable to find the MSVC installation directory. There
were many more I could have passed through which are set by vcvarsall,
but I tried to keep it simple and only pass through the important ones.

Differential Revision: https://reviews.llvm.org/D54963

llvm-svn: 347691
llvm/utils/lit/lit/TestingConfig.py