nixpkgs-suyu/pkgs/development/libraries/incrtcl/default.nix

44 lines
1.1 KiB
Nix
Raw Normal View History

{ stdenv, fetchurl, writeText, tcl }:
stdenv.mkDerivation rec {
pname = "incrtcl";
2019-11-28 03:28:51 +01:00
version = "4.2.0";
2018-11-01 20:52:49 +01:00
src = fetchurl {
url = "mirror://sourceforge/incrtcl/%5BIncr%20Tcl_Tk%5D-source/3.4/itcl${version}.tar.gz";
2019-11-28 03:28:51 +01:00
sha256 = "0w28v0zaraxcq1s9pa6cihqqwqvvwfgz275lks7w4gl7hxjxmasw";
};
buildInputs = [ tcl ];
configureFlags = [ "--with-tcl=${tcl}/lib" ];
enableParallelBuilding = true;
patchPhase = ''
substituteInPlace configure --replace "\''${TCL_SRC_DIR}/generic" "${tcl}/include"
'';
preConfigure = ''
configureFlags="--exec_prefix=$prefix $configureFlags"
'';
postInstall = ''
rmdir $out/bin
mv $out/lib/itcl${version}/* $out/lib
rmdir $out/lib/itcl${version}
'';
setupHook = writeText "setup-hook.sh" ''
export ITCL_LIBRARY=@out@/lib
'';
outputs = [ "out" "dev" "man" ];
2018-11-01 20:52:49 +01:00
meta = with stdenv.lib; {
homepage = "http://incrtcl.sourceforge.net/";
description = "Object Oriented Enhancements for Tcl/Tk";
license = licenses.tcltk;
platforms = platforms.unix;
maintainers = with maintainers; [ thoughtpolice ];
};
}