mirror of
https://github.com/NixOS/nix
synced 2025-06-26 11:41:15 +02:00
parent
a8edf185a9
commit
39d72640c2
8 changed files with 33 additions and 18 deletions
|
@ -153,7 +153,7 @@ static Symbol getName(const AttrName & name, EvalState & state, Env & env)
|
|||
}
|
||||
|
||||
|
||||
EvalState::EvalState()
|
||||
EvalState::EvalState(const Strings & _searchPath)
|
||||
: sWith(symbols.create("<with>"))
|
||||
, sOutPath(symbols.create("outPath"))
|
||||
, sDrvPath(symbols.create("drvPath"))
|
||||
|
@ -219,11 +219,10 @@ EvalState::EvalState()
|
|||
#endif
|
||||
|
||||
/* Initialise the Nix expression search path. */
|
||||
searchPathInsertionPoint = searchPath.end();
|
||||
Strings paths = tokenizeString<Strings>(getEnv("NIX_PATH", ""), ":");
|
||||
foreach (Strings::iterator, i, paths) addToSearchPath(*i);
|
||||
for (auto & i : _searchPath) addToSearchPath(i);
|
||||
for (auto & i : paths) addToSearchPath(i);
|
||||
addToSearchPath("nix=" + settings.nixDataDir + "/nix/corepkgs");
|
||||
searchPathInsertionPoint = searchPath.begin();
|
||||
|
||||
createBaseEnv();
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue