2015-06-19 15:54:35 +02:00
|
|
|
{ stdenv, src, pkgconfig, tcl, libXft, fontconfig, patches ? [], ... }:
|
2009-05-03 16:36:26 +02:00
|
|
|
|
|
|
|
stdenv.mkDerivation {
|
2015-04-27 05:55:07 +02:00
|
|
|
name = "tk-${tcl.version}";
|
2014-04-12 10:44:17 +02:00
|
|
|
|
2015-06-19 15:54:35 +02:00
|
|
|
inherit src patches;
|
2014-04-12 10:44:17 +02:00
|
|
|
|
2016-09-01 15:17:36 +02:00
|
|
|
outputs = [ "out" "man" "dev" ];
|
2016-09-01 15:15:07 +02:00
|
|
|
|
|
|
|
setOutputFlags = false;
|
2014-04-12 10:44:17 +02:00
|
|
|
|
2015-04-30 20:42:43 +02:00
|
|
|
preConfigure = ''
|
2016-09-01 15:15:07 +02:00
|
|
|
configureFlagsArray+=(--mandir=$man/share/man --enable-man-symlinks)
|
2015-04-30 20:42:43 +02:00
|
|
|
cd unix
|
|
|
|
'';
|
2014-04-12 10:44:17 +02:00
|
|
|
|
2016-09-01 15:15:07 +02:00
|
|
|
postInstall = ''
|
|
|
|
ln -s $out/bin/wish* $out/bin/wish
|
2016-12-25 20:35:51 +01:00
|
|
|
cp ../{unix,generic}/*.h $out/include
|
2016-09-01 15:15:07 +02:00
|
|
|
'';
|
|
|
|
|
2015-04-30 20:42:43 +02:00
|
|
|
configureFlags = [
|
|
|
|
"--with-tcl=${tcl}/lib"
|
|
|
|
];
|
2009-05-03 16:36:26 +02:00
|
|
|
|
2017-09-05 23:26:13 +02:00
|
|
|
nativeBuildInputs = [ pkgconfig ];
|
|
|
|
buildInputs = [ ]
|
2014-04-12 10:44:17 +02:00
|
|
|
++ stdenv.lib.optional stdenv.isDarwin fontconfig;
|
|
|
|
|
2016-06-20 10:33:44 +02:00
|
|
|
propagatedBuildInputs = [ tcl libXft ];
|
|
|
|
|
2014-04-13 14:56:54 +02:00
|
|
|
NIX_CFLAGS_LINK = if stdenv.isDarwin then "-lfontconfig" else null;
|
|
|
|
|
2009-05-03 16:36:26 +02:00
|
|
|
inherit tcl;
|
2010-05-28 12:57:50 +02:00
|
|
|
|
2015-04-27 05:55:07 +02:00
|
|
|
passthru = rec {
|
|
|
|
inherit (tcl) release version;
|
|
|
|
libPrefix = "tk${tcl.release}";
|
|
|
|
libdir = "lib/${libPrefix}";
|
2010-05-28 12:57:50 +02:00
|
|
|
};
|
2013-06-30 00:39:32 +02:00
|
|
|
|
2015-04-30 20:42:43 +02:00
|
|
|
meta = with stdenv.lib; {
|
2013-06-30 00:39:32 +02:00
|
|
|
description = "A widget toolkit that provides a library of basic elements for building a GUI in many different programming languages";
|
|
|
|
homepage = http://www.tcl.tk/;
|
2015-04-30 20:42:43 +02:00
|
|
|
license = licenses.tcltk;
|
|
|
|
platforms = platforms.all;
|
2016-07-29 01:19:08 +02:00
|
|
|
maintainers = with maintainers; [ lovek323 vrthra wkennington ];
|
2013-06-30 00:39:32 +02:00
|
|
|
};
|
2009-05-03 16:36:26 +02:00
|
|
|
}
|