3
0
Fork 0
forked from mirrors/nixpkgs
nixpkgs/pkgs/development/tools/fdroidserver/default.nix

66 lines
1.4 KiB
Nix
Raw Normal View History

2021-07-24 21:24:34 +01:00
{ fetchFromGitLab
, python
2021-07-24 21:24:34 +01:00
, lib
, apksigner
}:
python.pkgs.buildPythonApplication rec {
version = "2.0.3";
pname = "fdroidserver";
src = fetchFromGitLab {
owner = "fdroid";
repo = "fdroidserver";
rev = version;
sha256 = "sha256-/tX45t/DsWd0/R9VJJsqNjoOkgGIvqvq05YaVp0pLf0=";
};
postPatch = ''
substituteInPlace fdroidserver/common.py --replace "FDROID_PATH = os.path.realpath(os.path.join(os.path.dirname(__file__), '..'))" "FDROID_PATH = '$out/bin'"
'';
preConfigure = ''
${python.interpreter} setup.py compile_catalog
'';
postInstall = ''
patchShebangs gradlew-fdroid
install -m 0755 gradlew-fdroid $out/bin
'';
buildInputs = [ python.pkgs.Babel ];
propagatedBuildInputs = with python.pkgs; [
androguard
clint
defusedxml
GitPython
libcloud
mwclient
paramiko
pillow
pyasn1
pyasn1-modules
python-vagrant
pyyaml
qrcode
requests
ruamel-yaml
yamllint
];
2021-07-24 21:24:34 +01:00
makeWrapperArgs = [ "--prefix" "PATH" ":" "${lib.makeBinPath [ apksigner ]}" ];
2021-01-31 21:54:50 +00:00
# no tests
doCheck = false;
pythonImportsCheck = [ "fdroidserver" ];
meta = with lib; {
homepage = "https://f-droid.org";
description = "Server and tools for F-Droid, the Free Software repository system for Android";
license = licenses.agpl3;
maintainers = [ lib.maintainers.obfusk ];
};
}