diff options
author | Sandro Jäckel <sandro.jaeckel@gmail.com> | 2022-09-07 22:11:03 +0200 |
---|---|---|
committer | Rick van Schijndel <Mindavi@users.noreply.github.com> | 2022-09-21 18:43:01 +0200 |
commit | 73f3eedb29272774a33062120e59bafbd109a2cd (patch) | |
tree | 0d4ecd7484f98192bc23a6ddfbd196490caa8b1d /pkgs/tools/misc/expect | |
parent | cedd23b2156d5237401ad44e3280bdf7e1bc376b (diff) |
expect: fix cross compile
Diffstat (limited to 'pkgs/tools/misc/expect')
-rw-r--r-- | pkgs/tools/misc/expect/default.nix | 6 | ||||
-rw-r--r-- | pkgs/tools/misc/expect/fix-cross-compilation.patch | 11 |
2 files changed, 16 insertions, 1 deletions
diff --git a/pkgs/tools/misc/expect/default.nix b/pkgs/tools/misc/expect/default.nix index 5a792c040b39e..45f45e89e82d4 100644 --- a/pkgs/tools/misc/expect/default.nix +++ b/pkgs/tools/misc/expect/default.nix @@ -1,4 +1,4 @@ -{ lib, stdenv, buildPackages, fetchurl, tcl, makeWrapper, autoreconfHook, fetchpatch }: +{ lib, stdenv, buildPackages, fetchurl, tcl, makeWrapper, autoreconfHook, fetchpatch, substituteAll }: tcl.mkTclDerivation rec { pname = "expect"; @@ -14,6 +14,10 @@ tcl.mkTclDerivation rec { url = "https://raw.githubusercontent.com/buildroot/buildroot/c05e6aa361a4049eabd8b21eb64a34899ef83fc7/package/expect/0001-enable-cross-compilation.patch"; sha256 = "1jwx2l1slidvcpahxbyqs942l81jd62rzbxliyd9lwysk38c8b6b"; }) + (substituteAll { + src = ./fix-cross-compilation.patch; + tcl = "${buildPackages.tcl}/bin/tclsh"; + }) ]; postPatch = '' diff --git a/pkgs/tools/misc/expect/fix-cross-compilation.patch b/pkgs/tools/misc/expect/fix-cross-compilation.patch new file mode 100644 index 0000000000000..8edc4bea39d69 --- /dev/null +++ b/pkgs/tools/misc/expect/fix-cross-compilation.patch @@ -0,0 +1,11 @@ +--- a/Makefile.in 2022-09-07 21:46:37.090519258 +0200 ++++ b/Makefile.in 2022-09-07 21:46:21.462592279 +0200 +@@ -380,7 +380,7 @@ + cp $(DIST_ROOT)/$(PKG_DIR).tar.gz $(top_builddir) + + $(SCRIPTS): +- $(TCLSH) $(srcdir)/fixline1 $(SHORT_BINDIR) < $(srcdir)/example/$@ > $@ ++ @tcl@ $(srcdir)/fixline1 $(SHORT_BINDIR) < $(srcdir)/example/$@ > $@ + + ## We cannot use TCL_LIBS below (after TCL_LIB_SPEC) because its + ## expansion references the contents of LIBS, which contains linker |