From 0d8906702779ced65a76a38f08d16cbcfac92a1f Mon Sep 17 00:00:00 2001 From: Will Dietz Date: Fri, 6 May 2022 18:06:29 -0500 Subject: [PATCH] latencytop: fix hardcoded path to /bin/mount Fixes #171609. --- pkgs/os-specific/linux/latencytop/default.nix | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/pkgs/os-specific/linux/latencytop/default.nix b/pkgs/os-specific/linux/latencytop/default.nix index 56e412379f8..a48abf85831 100644 --- a/pkgs/os-specific/linux/latencytop/default.nix +++ b/pkgs/os-specific/linux/latencytop/default.nix @@ -1,10 +1,16 @@ -{ lib, stdenv, fetchurl, ncurses, glib, pkg-config, gtk2 }: +{ lib, stdenv, fetchurl, ncurses, glib, pkg-config, gtk2, util-linux }: stdenv.mkDerivation rec { pname = "latencytop"; version = "0.5"; - patchPhase = "sed -i s,/usr,$out, Makefile"; + postPatch = '' + sed -i s,/usr,$out, Makefile + + # Fix #171609 + substituteInPlace fsync.c --replace /bin/mount ${util-linux}/bin/mount + ''; + preInstall = "mkdir -p $out/sbin"; src = fetchurl {