mirror of
https://github.com/NixOS/nix
synced 2025-06-29 02:11:15 +02:00
Merge remote-tracking branch 'upstream/master' into single-ca-drv-build
This commit is contained in:
commit
3c8b5b6219
47 changed files with 372 additions and 252 deletions
|
@ -38,8 +38,9 @@ DrvInfo::DrvInfo(EvalState & state, ref<Store> store, const std::string & drvPat
|
|||
auto i = drv.outputs.find(outputName);
|
||||
if (i == drv.outputs.end())
|
||||
throw Error("derivation '%s' does not have output '%s'", store->printStorePath(drvPath), outputName);
|
||||
auto & [outputName, output] = *i;
|
||||
|
||||
auto optStorePath = i->second.pathOpt(*store, drv.name);
|
||||
auto optStorePath = output.pathOpt(*store, drv.name, outputName);
|
||||
if (optStorePath)
|
||||
outPath = store->printStorePath(*optStorePath);
|
||||
}
|
||||
|
|
|
@ -79,7 +79,7 @@ static void mkOutputString(EvalState & state, Value & v,
|
|||
const StorePath & drvPath, const BasicDerivation & drv,
|
||||
std::pair<string, DerivationOutput> o)
|
||||
{
|
||||
auto optOutputPath = o.second.pathOpt(*state.store, drv.name);
|
||||
auto optOutputPath = o.second.pathOpt(*state.store, drv.name, o.first);
|
||||
mkString(
|
||||
*state.allocAttr(v, state.symbols.create(o.first)),
|
||||
state.store->printStorePath(optOutputPath
|
||||
|
|
|
@ -212,7 +212,7 @@ static void fetch(EvalState & state, const Pos & pos, Value * * args, Value & v,
|
|||
: hashFile(htSHA256, path);
|
||||
if (hash != *expectedHash)
|
||||
throw Error((unsigned int) 102, "hash mismatch in file downloaded from '%s':\n wanted: %s\n got: %s",
|
||||
*url, expectedHash->to_string(Base32, true), hash->to_string(Base32, true));
|
||||
*url, expectedHash->to_string(Base32, true), hash.to_string(Base32, true));
|
||||
}
|
||||
|
||||
if (state.allowedPaths)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue