3
0
Fork 0
forked from mirrors/nixpkgs
nixpkgs/pkgs/applications/editors/texworks/default.nix

41 lines
1.2 KiB
Nix
Raw Normal View History

2021-02-03 13:36:44 +00:00
{ mkDerivation, lib, fetchFromGitHub, fetchpatch, cmake, pkg-config
2020-03-18 19:53:54 +00:00
, qtscript, poppler, hunspell
2017-09-18 23:06:57 +01:00
, withLua ? true, lua
2019-03-17 15:28:07 +00:00
, withPython ? true, python3 }:
2017-09-18 23:06:57 +01:00
2020-03-18 19:53:54 +00:00
mkDerivation rec {
pname = "texworks";
2020-04-01 21:08:03 +01:00
version = "0.6.5";
2017-09-18 23:06:57 +01:00
src = fetchFromGitHub {
owner = "TeXworks";
repo = "texworks";
rev = "release-${version}";
2020-04-01 21:08:03 +01:00
sha256 = "1lw1p4iyzxypvjhnav11g6rwf6gx7kyzwy2iprvv8zzpqcdkjp2z";
2017-09-18 23:06:57 +01:00
};
2021-02-03 13:36:44 +00:00
patches = [
(fetchpatch {
name = "fix-compilation-with-qt-5.15.patch";
url = "https://github.com/TeXworks/texworks/commit/a5352a3a94e3685125650b65e6197de060326cc2.patch";
sha256 = "0pf7h1m11x0s039bxknm7rxdp9b4g8ch86y38jlyy56c74mw97i6";
})
];
2020-03-18 19:53:54 +00:00
nativeBuildInputs = [ cmake pkg-config ];
buildInputs = [ qtscript poppler hunspell ]
2017-09-18 23:06:57 +01:00
++ lib.optional withLua lua
2019-03-17 15:28:07 +00:00
++ lib.optional withPython python3;
2017-09-18 23:06:57 +01:00
cmakeFlags = lib.optional withLua "-DWITH_LUA=ON"
++ lib.optional withPython "-DWITH_PYTHON=ON";
2020-03-18 19:53:54 +00:00
meta = with lib; {
2017-09-18 23:06:57 +01:00
description = "Simple TeX front-end program inspired by TeXShop";
homepage = "http://www.tug.org/texworks/";
2017-09-18 23:06:57 +01:00
license = licenses.gpl2Plus;
maintainers = with maintainers; [ dotlambda ];
platforms = with platforms; linux;
};
}