summary refs log tree commit diff
path: root/pkgs/development/libraries/libfaketime/default.nix
diff options
context:
space:
mode:
Diffstat (limited to 'pkgs/development/libraries/libfaketime/default.nix')
-rw-r--r--pkgs/development/libraries/libfaketime/default.nix12
1 files changed, 11 insertions, 1 deletions
diff --git a/pkgs/development/libraries/libfaketime/default.nix b/pkgs/development/libraries/libfaketime/default.nix
index cedd5f98027..cc9db8f7e66 100644
--- a/pkgs/development/libraries/libfaketime/default.nix
+++ b/pkgs/development/libraries/libfaketime/default.nix
@@ -1,4 +1,4 @@
-{ stdenv, fetchurl }:
+{ stdenv, fetchurl, bash, perl }:
 
 stdenv.mkDerivation rec {
   name = "libfaketime-${version}";
@@ -13,10 +13,20 @@ stdenv.mkDerivation rec {
     ./no-date-in-gzip-man-page.patch
   ];
 
+  postPatch = ''
+    patchShebangs test src
+    for a in test/functests/test_exclude_mono.sh src/faketime.c ; do
+      substituteInPlace $a \
+        --replace /bin/bash ${stdenv.shell}
+    done
+  '';
+
   preBuild = ''
     makeFlagsArray+=(PREFIX="$out" LIBDIRNAME=/lib)
   '';
 
+  checkInputs = [ perl ];
+
   meta = with stdenv.lib; {
     description = "Report faked system time to programs without having to change the system-wide time";
     homepage = "https://github.com/wolfcw/libfaketime/";