From 161414063fa9a87b61e5460c61ab1125c9e68e55 Mon Sep 17 00:00:00 2001 From: Matthew Bauer Date: Wed, 27 Jun 2018 16:47:21 -0400 Subject: [PATCH] treewide: use killall --- pkgs/applications/networking/syncthing-gtk/default.nix | 7 +++++-- pkgs/servers/http/myserver/default.nix | 4 ++-- pkgs/tools/misc/xfstests/default.nix | 9 ++++++--- 3 files changed, 13 insertions(+), 7 deletions(-) diff --git a/pkgs/applications/networking/syncthing-gtk/default.nix b/pkgs/applications/networking/syncthing-gtk/default.nix index be574acc8c75..9d720bee05e7 100644 --- a/pkgs/applications/networking/syncthing-gtk/default.nix +++ b/pkgs/applications/networking/syncthing-gtk/default.nix @@ -1,4 +1,7 @@ -{ stdenv, fetchFromGitHub, fetchpatch, libnotify, librsvg, darwin, psmisc, gtk3, libappindicator-gtk3, substituteAll, syncthing, wrapGAppsHook, gnome3, buildPythonApplication, dateutil, pyinotify, pygobject3, bcrypt, gobjectIntrospection }: +{ stdenv, fetchFromGitHub, fetchpatch, libnotify, librsvg, killall +, gtk3, libappindicator-gtk3, substituteAll, syncthing, wrapGAppsHook +, gnome3, buildPythonApplication, dateutil, pyinotify, pygobject3 +, bcrypt, gobjectIntrospection }: buildPythonApplication rec { version = "0.9.4"; @@ -35,7 +38,7 @@ buildPythonApplication rec { }) (substituteAll { src = ./paths.patch; - killall = "${if stdenv.isDarwin then darwin.shell_cmds else psmisc}/bin/killall"; + killall = "${killall}/bin/killall"; syncthing = "${syncthing}/bin/syncthing"; }) ]; diff --git a/pkgs/servers/http/myserver/default.nix b/pkgs/servers/http/myserver/default.nix index fa3b57a0b22e..a18ac202a4a2 100644 --- a/pkgs/servers/http/myserver/default.nix +++ b/pkgs/servers/http/myserver/default.nix @@ -1,5 +1,5 @@ { lib, fetchurl, stdenv, libgcrypt, libevent, libidn, gnutls -, libxml2, zlib, guile, texinfo, cppunit, psmisc }: +, libxml2, zlib, guile, texinfo, cppunit, killall }: let version = "0.11"; in @@ -26,7 +26,7 @@ stdenv.mkDerivation rec { # On GNU/Linux the `test_suite' process sometimes stays around, so # forcefully terminate it. - postCheck = lib.optionalString stdenv.isLinux "${psmisc}/bin/killall test_suite || true"; + postCheck = "${killall}/bin/killall test_suite || true"; meta = { description = "GNU MyServer, a powerful and easy to configure web server"; diff --git a/pkgs/tools/misc/xfstests/default.nix b/pkgs/tools/misc/xfstests/default.nix index e6c67ddb9bb8..80a728747fef 100644 --- a/pkgs/tools/misc/xfstests/default.nix +++ b/pkgs/tools/misc/xfstests/default.nix @@ -1,5 +1,6 @@ -{ stdenv, acl, attr, autoconf, automake, bash, bc, coreutils, e2fsprogs, fetchgit, fio, gawk, keyutils -, lib, libaio, libcap, libtool, libuuid, libxfs, lvm2, openssl, perl, procps, psmisc, quota, su +{ stdenv, acl, attr, autoconf, automake, bash, bc, coreutils, e2fsprogs +, fetchgit, fio, gawk, keyutils, killall, lib, libaio, libcap, libtool +, libuuid, libxfs, lvm2, openssl, perl, procps, quota, su , time, utillinux, which, writeScript, xfsprogs }: stdenv.mkDerivation { @@ -90,7 +91,9 @@ stdenv.mkDerivation { ln -s @out@/lib/xfstests/$f $f done - export PATH=${lib.makeBinPath [acl attr bc e2fsprogs fio gawk keyutils libcap lvm2 perl procps psmisc quota utillinux which xfsprogs]}:$PATH + export PATH=${lib.makeBinPath [acl attr bc e2fsprogs fio gawk keyutils + libcap lvm2 perl procps killall quota + utillinux which xfsprogs]}:$PATH exec ./check "$@" '';