1{ buildPythonPackage, lib
2, cython, libseccomp
3}:
4
5buildPythonPackage rec {
6 pname = "libseccomp";
7 version = libseccomp.version;
8 src = libseccomp.pythonsrc;
9
10 VERSION_RELEASE = version; # used by build system
11
12 nativeBuildInputs = [ cython ];
13 buildInputs = [ libseccomp ];
14
15 unpackCmd = "tar xf $curSrc";
16 doInstallCheck = true;
17
18 postPatch = ''
19 substituteInPlace ./setup.py \
20 --replace 'extra_objects=["../.libs/libseccomp.a"]' \
21 'libraries=["seccomp"]'
22 '';
23
24 meta = with lib; {
25 description = "Python bindings for libseccomp";
26 license = with licenses; [ lgpl21 ];
27 maintainers = with maintainers; [ thoughtpolice ];
28 };
29}