expect: Simplify package with tcl.mkTclDerivation
This commit is contained in:
parent
98b8fc3579
commit
311ea59a3e
|
@ -1,6 +1,6 @@
|
||||||
{ lib, stdenv, buildPackages, fetchurl, tcl, makeWrapper, autoreconfHook, fetchpatch }:
|
{ lib, stdenv, buildPackages, fetchurl, tcl, makeWrapper, autoreconfHook, fetchpatch }:
|
||||||
|
|
||||||
stdenv.mkDerivation rec {
|
tcl.mkTclDerivation rec {
|
||||||
pname = "expect";
|
pname = "expect";
|
||||||
version = "5.45.4";
|
version = "5.45.4";
|
||||||
|
|
||||||
|
@ -20,24 +20,14 @@ stdenv.mkDerivation rec {
|
||||||
sed -i "s,/bin/stty,$(type -p stty),g" configure.in
|
sed -i "s,/bin/stty,$(type -p stty),g" configure.in
|
||||||
'';
|
'';
|
||||||
|
|
||||||
nativeBuildInputs = [ autoreconfHook makeWrapper tcl ];
|
nativeBuildInputs = [ autoreconfHook makeWrapper ];
|
||||||
buildInputs = [ tcl ];
|
|
||||||
|
|
||||||
strictDeps = true;
|
strictDeps = true;
|
||||||
hardeningDisable = [ "format" ];
|
hardeningDisable = [ "format" ];
|
||||||
|
|
||||||
configureFlags = [
|
postInstall = lib.optionalString stdenv.isDarwin ''
|
||||||
"--with-tcl=${buildPackages.tcl}/lib"
|
|
||||||
"--with-tclinclude=${tcl}/include"
|
|
||||||
"--exec-prefix=${placeholder "out"}"
|
|
||||||
];
|
|
||||||
|
|
||||||
postInstall = ''
|
|
||||||
for i in $out/bin/*; do
|
for i in $out/bin/*; do
|
||||||
wrapProgram $i \
|
wrapProgram $i --prefix DYLD_LIBRARY_PATH : $out/lib/expect${version}
|
||||||
--prefix PATH : "${tcl}/bin" \
|
|
||||||
--prefix TCLLIBPATH ' ' $out/lib/* \
|
|
||||||
${lib.optionalString stdenv.isDarwin "--prefix DYLD_LIBRARY_PATH : $out/lib/expect${version}"}
|
|
||||||
done
|
done
|
||||||
'';
|
'';
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue