nixpkgs/pkgs/applications/office/paperwork/paperwork-backend.nix

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

93 lines
1.5 KiB
Nix
Raw Normal View History

2020-10-31 12:00:00 +00:00
{ buildPythonPackage
, lib
, fetchFromGitLab
, pyenchant
2021-01-06 12:00:00 +00:00
, scikit-learn
2020-10-31 12:00:00 +00:00
, pypillowfight
, pycountry
, whoosh
, termcolor
, pygobject3
, pyocr
, natsort
, libinsane
, distro
, openpaperwork-core
, openpaperwork-gtk
, psutil
, gtk3
, poppler_gi
, gettext
, which
, shared-mime-info
, libreoffice
, unittestCheckHook
, setuptools-scm
2020-10-31 12:00:00 +00:00
}:
buildPythonPackage rec {
pname = "paperwork-backend";
inherit (import ./src.nix { inherit fetchFromGitLab; }) version src;
format = "pyproject";
2020-10-31 12:00:00 +00:00
sourceRoot = "${src.name}/paperwork-backend";
2020-10-31 12:00:00 +00:00
patches = [
# disables a flaky test https://gitlab.gnome.org/World/OpenPaperwork/paperwork/-/issues/1035#note_1493700
./flaky_test.patch
];
patchFlags = [ "-p2" ];
postPatch = ''
2020-10-31 12:00:00 +00:00
chmod a+w -R ..
patchShebangs ../tools
'';
propagatedBuildInputs = [
distro
gtk3
libinsane
natsort
openpaperwork-core
2020-10-31 12:00:00 +00:00
pyenchant
pycountry
pygobject3
pyocr
pypillowfight
poppler_gi
scikit-learn
termcolor
whoosh
2020-10-31 12:00:00 +00:00
];
nativeBuildInputs = [
gettext
shared-mime-info
which
setuptools-scm
];
2020-10-31 12:00:00 +00:00
preBuild = ''
make l10n_compile
'';
nativeCheckInputs = [
libreoffice
openpaperwork-gtk
psutil
unittestCheckHook
];
preCheck = ''
export HOME=$TMPDIR
'';
2020-10-31 12:00:00 +00:00
meta = with lib; {
2020-10-31 12:00:00 +00:00
description = "Backend part of Paperwork (Python API, no UI)";
homepage = "https://openpaper.work";
license = licenses.gpl3Plus;
maintainers = with maintainers; [ aszlig symphorien ];
2020-10-31 12:00:00 +00:00
};
}