Skip to content

Commit

Permalink
Actually fix nixDataDir in non-canonical path
Browse files Browse the repository at this point in the history
  • Loading branch information
shlevy committed Feb 28, 2018
1 parent 8a5da93 commit 14ca856
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src/libexpr/eval.cc
Original file line number Diff line number Diff line change
Expand Up @@ -313,7 +313,7 @@ EvalState::EvalState(const Strings & _searchPath, ref<Store> store)
for (auto & i : _searchPath) addToSearchPath(i);
for (auto & i : paths) addToSearchPath(i);
}
addToSearchPath("nix=" + canonPath(settings.nixDataDir + "/nix/corepkgs"));
addToSearchPath("nix=" + canonPath(settings.nixDataDir + "/nix/corepkgs", true));

if (settings.restrictEval || settings.pureEval) {
allowedPaths = PathSet();
Expand Down
2 changes: 1 addition & 1 deletion src/libexpr/primops.cc
Original file line number Diff line number Diff line change
Expand Up @@ -2236,7 +2236,7 @@ void EvalState::createBaseEnv()

/* Add a wrapper around the derivation primop that computes the
`drvPath' and `outPath' attributes lazily. */
string path = settings.nixDataDir + "/nix/corepkgs/derivation.nix";
string path = canonPath(settings.nixDataDir + "/nix/corepkgs/derivation.nix", true);
sDerivationNix = symbols.create(path);
evalFile(path, v);
addConstant("derivation", v);
Expand Down

0 comments on commit 14ca856

Please sign in to comment.