lol
1{ lib
2, stdenv
3, callPackage
4, fetchurl
5, fetchpatch
6, tcl
7, ...
8} @ args:
9
10callPackage ./generic.nix (args // {
11
12 src = fetchurl {
13 url = "mirror://sourceforge/tcl/tk${tcl.version}.1-src.tar.gz"; # TODO: remove '.1' for v8.6.10 or v8.7.x
14 sha256 = "1gh9k7l76qg9l0sb78ijw9xz4xl1af47aqbdifb6mjpf3cbsnv00";
15 };
16
17 patches = [ ./different-prefix-with-tcl.patch ] ++ lib.optionals stdenv.isDarwin [
18 ./Fix-bad-install_name-for-libtk8.6.dylib.patch
19 # Define MODULE_SCOPE before including tkPort.h
20 # https://core.tcl-lang.org/tk/info/dba9f5ce3b
21 (fetchpatch {
22 name = "module_scope.patch";
23 url = "https://core.tcl-lang.org/tk/vpatch?from=ef6c6960c53ea30c&to=9b8aa74eebed509a";
24 extraPrefix = "";
25 sha256 = "0crhf4zrzdpc1jdgyv6l6mxqgmny12r3i39y1i0j8q3pbqkd04bv";
26 })
27 ];
28
29})