diff options
author | Vincent Ambo <mail@tazj.in> | 2020-11-21T17·22+0100 |
---|---|---|
committer | tazjin <mail@tazj.in> | 2020-11-21T23·18+0000 |
commit | 5a00e58904df83c168f3971984916d479277e409 (patch) | |
tree | 183ffc507c3a720c4c97b760dc75fa1d6141060a /third_party/nix/src/libstore | |
parent | e9088826109dfcc550f599ccdc7926a0eed1cd50 (diff) |
chore(3p): Bump nixpkgs to nixos-unstable from 2020-11-21 r/1894
Included fixes for random breakage: * 3p/awscli: pick from the stable channel; it is broken on unstable * 3p/googletest: bumped version & removed patches that nixpkgs applies * 3p/lisp/cffi: bumped library version for SBCL compat * 3p/nix: fix libsystemd attribute * 3p/nix: reformatted (clang-format handling of ternaries changed) * glittershark/home: Use home-manager from nixkpgs * glittershark/kernel: bumped linux-ck patch hash * glittershark/kernel: removed "patch patch" * multi/whitby: Use home-manager from nixpkgs * tazjin/frog: drop Sourcetrail (it doesn't build currently) Note that in addition to these changes, some previous CLs updated the versions of git and cgit which was necessary for this channel bump, but which could not be done in the same commit due to the nature of the subtree merges. Change-Id: If2563e8a68e2750c4b913a976ff7b93b42e8b7f3 Reviewed-on: https://cl.tvl.fyi/c/depot/+/2110 Tested-by: BuildkiteCI Reviewed-by: multi <depot@in-addr.xyz> Reviewed-by: glittershark <grfn@gws.fyi>
Diffstat (limited to 'third_party/nix/src/libstore')
-rw-r--r-- | third_party/nix/src/libstore/binary-cache-store.cc | 8 | ||||
-rw-r--r-- | third_party/nix/src/libstore/build.cc | 17 | ||||
-rw-r--r-- | third_party/nix/src/libstore/download.cc | 22 | ||||
-rw-r--r-- | third_party/nix/src/libstore/local-fs-store.cc | 6 | ||||
-rw-r--r-- | third_party/nix/src/libstore/worker-protocol.hh | 2 |
5 files changed, 26 insertions, 29 deletions
diff --git a/third_party/nix/src/libstore/binary-cache-store.cc b/third_party/nix/src/libstore/binary-cache-store.cc index e5b7ef2cdc3e..0b04e972da7c 100644 --- a/third_party/nix/src/libstore/binary-cache-store.cc +++ b/third_party/nix/src/libstore/binary-cache-store.cc @@ -214,10 +214,10 @@ void BinaryCacheStore::addToStore(const ValidPathInfo& info, /* Atomically write the NAR file. */ narInfo->url = "nar/" + narInfo->fileHash.to_string(Base32, false) + ".nar" + - (compression == "xz" ? ".xz" - : compression == "bzip2" - ? ".bz2" - : compression == "br" ? ".br" : ""); + (compression == "xz" ? ".xz" + : compression == "bzip2" ? ".bz2" + : compression == "br" ? ".br" + : ""); if ((repair != 0u) || !fileExists(narInfo->url)) { stats.narWrite++; upsertFile(narInfo->url, *narCompressed, "application/x-nix-nar"); diff --git a/third_party/nix/src/libstore/build.cc b/third_party/nix/src/libstore/build.cc index e50f4cfa9901..2479b9a59c6c 100644 --- a/third_party/nix/src/libstore/build.cc +++ b/third_party/nix/src/libstore/build.cc @@ -1462,12 +1462,10 @@ void DerivationGoal::tryToBuild() { bool buildLocally = buildMode != bmNormal || parsedDrv->willBuildLocally(); auto started = [&]() { - auto msg = fmt(buildMode == bmRepair - ? "repairing outputs of '%s'" - : buildMode == bmCheck - ? "checking outputs of '%s'" - : nrRounds > 1 ? "building '%s' (round %d/%d)" - : "building '%s'", + auto msg = fmt(buildMode == bmRepair ? "repairing outputs of '%s'" + : buildMode == bmCheck ? "checking outputs of '%s'" + : nrRounds > 1 ? "building '%s' (round %d/%d)" + : "building '%s'", drvPath, curRound, nrRounds); if (hook) { @@ -1748,10 +1746,9 @@ void DerivationGoal::buildDone() { else { st = dynamic_cast<NotDeterministic*>(&e) != nullptr ? BuildResult::NotDeterministic - : statusOk(status) - ? BuildResult::OutputRejected - : fixedOutput || diskFull ? BuildResult::TransientFailure - : BuildResult::PermanentFailure; + : statusOk(status) ? BuildResult::OutputRejected + : fixedOutput || diskFull ? BuildResult::TransientFailure + : BuildResult::PermanentFailure; } done(st, e.msg()); diff --git a/third_party/nix/src/libstore/download.cc b/third_party/nix/src/libstore/download.cc index ee2ce8152dbc..a2eed7ced8e3 100644 --- a/third_party/nix/src/libstore/download.cc +++ b/third_party/nix/src/libstore/download.cc @@ -435,17 +435,17 @@ struct CurlDownloader : public Downloader { code == CURLE_ABORTED_BY_CALLBACK && _isInterrupted ? DownloadError(Interrupted, fmt("%s of '%s' was interrupted", request.verb(), request.uri)) - : httpStatus != 0 - ? DownloadError( - err, fmt("unable to %s '%s': HTTP error %d", - request.verb(), request.uri, httpStatus) + - (code == CURLE_OK - ? "" - : fmt(" (curl error: %s)", - curl_easy_strerror(code)))) - : DownloadError(err, fmt("unable to %s '%s': %s (%d)", - request.verb(), request.uri, - curl_easy_strerror(code), code)); + : httpStatus != 0 + ? DownloadError( + err, + fmt("unable to %s '%s': HTTP error %d", request.verb(), + request.uri, httpStatus) + + (code == CURLE_OK ? "" + : fmt(" (curl error: %s)", + curl_easy_strerror(code)))) + : DownloadError( + err, fmt("unable to %s '%s': %s (%d)", request.verb(), + request.uri, curl_easy_strerror(code), code)); /* If this is a transient error, then maybe retry the download after a while. If we're writing to a diff --git a/third_party/nix/src/libstore/local-fs-store.cc b/third_party/nix/src/libstore/local-fs-store.cc index 2ebf99a9b5a2..f2235bad7677 100644 --- a/third_party/nix/src/libstore/local-fs-store.cc +++ b/third_party/nix/src/libstore/local-fs-store.cc @@ -38,9 +38,9 @@ struct LocalStoreAccessor : public FSAccessor { throw Error(format("file '%1%' has unsupported type") % path); } - return {S_ISREG(st.st_mode) - ? Type::tRegular - : S_ISLNK(st.st_mode) ? Type::tSymlink : Type::tDirectory, + return {S_ISREG(st.st_mode) ? Type::tRegular + : S_ISLNK(st.st_mode) ? Type::tSymlink + : Type::tDirectory, S_ISREG(st.st_mode) ? static_cast<uint64_t>(st.st_size) : 0, S_ISREG(st.st_mode) && ((st.st_mode & S_IXUSR) != 0u)}; } diff --git a/third_party/nix/src/libstore/worker-protocol.hh b/third_party/nix/src/libstore/worker-protocol.hh index e2f40a449d86..47095253a129 100644 --- a/third_party/nix/src/libstore/worker-protocol.hh +++ b/third_party/nix/src/libstore/worker-protocol.hh @@ -53,7 +53,7 @@ typedef enum { } WorkerOp; #define STDERR_NEXT 0x6f6c6d67 -#define STDERR_READ 0x64617461 // data needed from source +#define STDERR_READ 0x64617461 // data needed from source #define STDERR_WRITE 0x64617416 // data for sink #define STDERR_LAST 0x616c7473 #define STDERR_ERROR 0x63787470 |