1{
2 lib,
3 buildPythonApplication,
4 fetchFromGitLab,
5 makeWrapper,
6 cmake,
7 six,
8 pyparsing,
9 asn1ate,
10 colored,
11}:
12
13buildPythonApplication rec {
14 pname = "asn2quickder";
15 version = "1.7.1";
16
17 src = fetchFromGitLab {
18 owner = "arpa2";
19 repo = "quick-der";
20 rev = "v${version}";
21 hash = "sha256-f+ph5PL+uWRkswpOLDwZFWjh938wxoJ6xocJZ2WZLEk=";
22 };
23
24 postPatch = ''
25 patchShebangs ./python/scripts/*
26
27 # Unpin pyparsing 3.0.0. Issue resolved in latest version.
28 substituteInPlace setup.py --replace 'pyparsing==3.0.0' 'pyparsing'
29 '';
30
31 dontUseCmakeConfigure = true;
32
33 nativeBuildInputs = [
34 makeWrapper
35 cmake
36 ];
37
38 propagatedBuildInputs = [
39 pyparsing
40 asn1ate
41 six
42 colored
43 ];
44
45 doCheck = false; # Flaky tests
46
47 meta = with lib; {
48 description = "ASN.1 compiler with a backend for Quick DER";
49 homepage = "https://gitlab.com/arpa2/quick-der";
50 license = licenses.bsd3;
51 platforms = platforms.linux;
52 maintainers = with maintainers; [ leenaars ];
53 };
54}