From 6dff63294a8bd264c8b93f89c721022de2abb072 Mon Sep 17 00:00:00 2001 From: sternenseemann <0rpkxez4ksa01gb3typccl0i@systemli.org> Date: Wed, 14 Apr 2021 16:41:11 +0200 Subject: [PATCH] netbsd: take fetchcvs from buildPackages to fix eval For some reason fetchcvs was taken from the cross package set when cross compiling netbsd.* instead of from buildPackages. I suspect that this was no issue previously because it just could be substituted as it only ever produced fixed output derivations. However since 00a2084a409e65e9781e9792644bbf5b1b1bca5a the evaluation of fetchcvs would depend on `stdenv.cc` (via its openssh dependency). Since netbsd.libc is required to evaluate stdenv.cc this caused a infinite recursion when staging the cross stdenv for pkgsCross.amd64-netbsd. The fix for this is pretty easy: Just take fetchcvs from buildPackages explicitly instead of hoping for mkDerivation to get it right. Resolves #119323. --- pkgs/os-specific/bsd/netbsd/default.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pkgs/os-specific/bsd/netbsd/default.nix b/pkgs/os-specific/bsd/netbsd/default.nix index b86891352f07..ab202c275ac8 100644 --- a/pkgs/os-specific/bsd/netbsd/default.nix +++ b/pkgs/os-specific/bsd/netbsd/default.nix @@ -1,8 +1,8 @@ -{ stdenv, stdenvNoCC, fetchcvs, lib, groff, mandoc, zlib, bison, flex +{ stdenv, stdenvNoCC, lib, groff, mandoc, zlib, bison, flex , writeText, buildPackages, splicePackages, symlinkJoin }: let - fetchNetBSD = path: version: sha256: fetchcvs { + fetchNetBSD = path: version: sha256: buildPackages.fetchcvs { cvsRoot = ":pserver:anoncvs@anoncvs.NetBSD.org:/cvsroot"; module = "src/${path}"; inherit sha256;