patches: Add fix for pymilter build

This commit is contained in:
Charlotte Van Petegem 2024-06-23 11:35:16 +02:00
parent 03a97915f5
commit 9e89a50319
No known key found for this signature in database
GPG key ID: 019E764B7184435A

48
patches/321446.patch Normal file
View file

@ -0,0 +1,48 @@
diff --git a/pkgs/development/python-modules/pymilter/default.nix b/pkgs/development/python-modules/pymilter/default.nix
index 32b7cfcc9bbcd6..6d9338dbc1b90e 100644
--- a/pkgs/development/python-modules/pymilter/default.nix
+++ b/pkgs/development/python-modules/pymilter/default.nix
@@ -3,9 +3,8 @@
python,
buildPythonPackage,
fetchFromGitHub,
- fetchpatch,
libmilter,
- bsddb3,
+ berkeleydb,
pydns,
iana-etc,
libredirect,
@@ -14,29 +13,22 @@
buildPythonPackage rec {
pname = "pymilter";
- version = "1.0.5";
+ version = "1.0.6";
format = "setuptools";
src = fetchFromGitHub {
owner = "sdgathman";
repo = pname;
rev = "${pname}-${version}";
- hash = "sha256-gZUWEDVZfDRiOOdG3lpiQldHxm/93l8qYVOHOEpHhzQ=";
+ hash = "sha256-plaWXwDAIsVzEtrabZuZj7T4WNfz2ntQHgcMCVf5S70=";
};
buildInputs = [ libmilter ];
nativeCheckInputs = [ pyasyncore ];
propagatedBuildInputs = [
- bsddb3
+ berkeleydb
pydns
];
- patches = [
- (fetchpatch { # https://github.com/sdgathman/pymilter/pull/57
- name = "Remove-calls-to-the-deprecated-method-assertEquals";
- url = "https://github.com/sdgathman/pymilter/commit/1ead9028fc63ae3ec6ea3b0c438e6ed088a2b20e.patch";
- hash = "sha256-/5LlDR15nMR3l7rkVjT3w4FbDTFAAgNdERWlPNL2TVg=";
- })
- ];
preBuild = ''
sed -i 's/import thread/import _thread as thread/' Milter/greylist.py