diffutils: enable strictDeps, enable structuredAttrs, use finalAttrs (#548585)

This commit is contained in:
Stefan Frijters
2026-08-14 11:54:43 +00:00
committed by GitHub

View File

@@ -12,12 +12,12 @@
# cgit) that are needed here should be included directly in Nixpkgs as
# files.
stdenv.mkDerivation rec {
stdenv.mkDerivation (finalAttrs: {
pname = "diffutils";
version = "3.12";
src = fetchurl {
url = "mirror://gnu/diffutils/diffutils-${version}.tar.xz";
url = "mirror://gnu/diffutils/diffutils-${finalAttrs.version}.tar.xz";
hash = "sha256-fIt/n8hgkUH96pzs6FJJ0whiQ5H/Yd7a9Sj8szdyff0=";
};
@@ -42,6 +42,8 @@ stdenv.mkDerivation rec {
# If no explicit coreutils is given, use the one from stdenv.
buildInputs = [ coreutils ];
strictDeps = true;
# Disable stack-related gnulib tests on x86_64-darwin because they have problems running under
# Rosetta 2: test-c-stack hangs, test-sigsegv-catch-stackoverflow and test-sigaction fail.
# Disable all gnulib tests when building on Darwin due to test-nl_langinfo-mt failure
@@ -78,6 +80,8 @@ stdenv.mkDerivation rec {
# Test failure on QEMU only (#300550)
doCheck = !stdenv.buildPlatform.isRiscV64;
__structuredAttrs = true;
meta = {
homepage = "https://www.gnu.org/software/diffutils/diffutils.html";
description = "Commands for showing the differences between files (diff, cmp, etc.)";
@@ -88,4 +92,4 @@ stdenv.mkDerivation rec {
helsinki-Jo
];
};
}
})