Skip to content

Commit 6334286

Browse files
glog: patch /usr/bin/true in tests (#378903)
2 parents 89cfd9a + 4f680c2 commit 6334286

File tree

1 file changed

+8
-2
lines changed

1 file changed

+8
-2
lines changed

pkgs/by-name/gl/glog/package.nix

+8-2
Original file line numberDiff line numberDiff line change
@@ -6,9 +6,10 @@
66
gflags,
77
gtest,
88
perl,
9+
pkgsBuildHost,
910
}:
1011

11-
stdenv.mkDerivation rec {
12+
stdenv.mkDerivation (finalAttrs: rec {
1213
pname = "glog";
1314
version = "0.7.1";
1415

@@ -19,6 +20,11 @@ stdenv.mkDerivation rec {
1920
sha256 = "sha256-+nwWP6VBmhgU7GCPSEGUzvUSCc48wXME181WpJ5ABP4=";
2021
};
2122

23+
postPatch = lib.optionalString finalAttrs.doCheck ''
24+
substituteInPlace src/logging_unittest.cc \
25+
--replace-warn "/usr/bin/true" "${pkgsBuildHost.coreutils}/bin/true"
26+
'';
27+
2228
nativeBuildInputs = [ cmake ];
2329

2430
buildInputs = [ gtest ];
@@ -90,4 +96,4 @@ stdenv.mkDerivation rec {
9096
r-burns
9197
];
9298
};
93-
}
99+
})

0 commit comments

Comments
 (0)