From c4583f787d535d4bc7c7805738f77abac702f130 Mon Sep 17 00:00:00 2001 From: Rodrigo Arias Mallo Date: Mon, 10 Feb 2025 17:16:57 +0100 Subject: [PATCH] Fix Nanos6 build from git MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The src.rev attribute is not available as it comes from source before the recursive operator. Instead, simply get it from the function inputs. Cc: Aleix Boné Reviewed-by: Aleix Roca Nonell --- pkgs/nanos6/default.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pkgs/nanos6/default.nix b/pkgs/nanos6/default.nix index 6babdf1..fabb1e4 100644 --- a/pkgs/nanos6/default.nix +++ b/pkgs/nanos6/default.nix @@ -48,7 +48,7 @@ let source = if (useGit) then git else release; in - stdenv.mkDerivation (source // rec { + stdenv.mkDerivation (source // { pname = "nanos6"; prePatch = '' @@ -62,7 +62,7 @@ in export CACHELINE_WIDTH=${toString cachelineBytes} ./autogen.sh '' + lib.optionalString (useGit) '' - export NANOS6_GIT_VERSION=${src.rev} + export NANOS6_GIT_VERSION=${gitCommit} export NANOS6_GIT_BRANCH=${gitBranch} '';