depot/third_party/nixpkgs/pkgs/development/python-modules/django/3.nix

49 lines
928 B
Nix
Raw Normal View History

{ lib, stdenv
, buildPythonPackage
, fetchPypi
, substituteAll
, geos
, gdal
, asgiref
, pytz
, sqlparse
, pythonOlder
, withGdal ? false
}:
buildPythonPackage rec {
pname = "Django";
version = "3.2.8";
disabled = pythonOlder "3.7";
src = fetchPypi {
inherit pname version;
sha256 = "f6d2c4069c9b9bfac03bedff927ea1f9e0d29e34525cec8a68fd28eb2a8df7af";
};
patches = lib.optional withGdal
(substituteAll {
src = ./django_3_set_geos_gdal_lib.patch;
geos = geos;
gdal = gdal;
extension = stdenv.hostPlatform.extensions.sharedLibrary;
});
propagatedBuildInputs = [
asgiref
pytz
sqlparse
];
# too complicated to setup
doCheck = false;
meta = with lib; {
description = "A high-level Python Web framework";
homepage = "https://www.djangoproject.com/";
license = licenses.bsd3;
maintainers = with maintainers; [ georgewhewell lsix ];
};
}