about summary refs log tree commit diff
path: root/pkgs/tools/misc/expect
diff options
context:
space:
mode:
authorAndrew Brooks <andrew.brooks@flightaware.com>2021-04-30 17:59:45 -0500
committerAndrew Brooks <andrew.brooks@flightaware.com>2021-05-21 15:18:08 -0500
commit311ea59a3e9314fd0df316409766d7c3cd0ccc6b (patch)
tree03d72694066e06130afb90c111cfcf3b3cd32365 /pkgs/tools/misc/expect
parent98b8fc35791d1883cc8e43c755507a712f8c40c4 (diff)
expect: Simplify package with tcl.mkTclDerivation
Diffstat (limited to 'pkgs/tools/misc/expect')
-rw-r--r--pkgs/tools/misc/expect/default.nix18
1 files changed, 4 insertions, 14 deletions
diff --git a/pkgs/tools/misc/expect/default.nix b/pkgs/tools/misc/expect/default.nix
index 1315ac8540cb5..03e8e260ac6b2 100644
--- a/pkgs/tools/misc/expect/default.nix
+++ b/pkgs/tools/misc/expect/default.nix
@@ -1,6 +1,6 @@
 { lib, stdenv, buildPackages, fetchurl, tcl, makeWrapper, autoreconfHook, fetchpatch }:
 
-stdenv.mkDerivation rec {
+tcl.mkTclDerivation rec {
   pname = "expect";
   version = "5.45.4";
 
@@ -20,24 +20,14 @@ stdenv.mkDerivation rec {
     sed -i "s,/bin/stty,$(type -p stty),g" configure.in
   '';
 
-  nativeBuildInputs = [ autoreconfHook makeWrapper tcl ];
-  buildInputs = [ tcl ];
+  nativeBuildInputs = [ autoreconfHook makeWrapper ];
 
   strictDeps = true;
   hardeningDisable = [ "format" ];
 
-  configureFlags = [
-    "--with-tcl=${buildPackages.tcl}/lib"
-    "--with-tclinclude=${tcl}/include"
-    "--exec-prefix=${placeholder "out"}"
-  ];
-
-  postInstall = ''
+  postInstall = lib.optionalString stdenv.isDarwin ''
     for i in $out/bin/*; do
-      wrapProgram $i \
-        --prefix PATH : "${tcl}/bin" \
-        --prefix TCLLIBPATH ' ' $out/lib/* \
-        ${lib.optionalString stdenv.isDarwin "--prefix DYLD_LIBRARY_PATH : $out/lib/expect${version}"}
+      wrapProgram $i --prefix DYLD_LIBRARY_PATH : $out/lib/expect${version}
     done
   '';