python3Packages.asn1: init at 2.4.1

This commit is contained in:
Fabian Affolter 2021-08-24 17:02:01 +02:00 committed by Martin Weinelt
parent e0a2c1b354
commit 136e531d7d
2 changed files with 47 additions and 0 deletions

View File

@ -0,0 +1,45 @@
{ lib
, buildPythonPackage
, pythonOlder
, fetchFromGitHub
, future
, pytestCheckHook
}:
buildPythonPackage rec {
pname = "asn1";
version = "2.4.1";
disabled = pythonOlder "3.7";
src = fetchFromGitHub {
owner = "andrivet";
repo = "python-asn1";
rev = "v${version}";
sha256 = "0g2d5cr1pxsm5ackba7padf7gvlgrgv807kh0312s5axjd2cww2l";
};
propagatedBuildInputs = [
future
];
checkInputs = [
pytestCheckHook
];
postPatch = ''
substituteInPlace setup.py \
--replace "enum-compat" ""
'';
pytestFlagsArray = [ "tests/test_asn1.py" ];
pythonImportsCheck = [ "asn1" ];
meta = with lib; {
description = "Python ASN.1 encoder and decoder";
homepage = "https://github.com/andrivet/python-asn1";
license = licenses.mit;
maintainers = with maintainers; [ fab ];
};
}

View File

@ -565,6 +565,8 @@ in {
asgiref = callPackage ../development/python-modules/asgiref { };
asn1 = callPackage ../development/python-modules/asn1 { };
asn1ate = callPackage ../development/python-modules/asn1ate { };
asn1crypto = callPackage ../development/python-modules/asn1crypto { };