1{
2 lib,
3 fetchFromGitHub,
4 buildPythonPackage,
5 cython_0,
6 pkg-config,
7 libgbinder,
8}:
9
10buildPythonPackage rec {
11 pname = "gbinder-python";
12 version = "1.1.1";
13 format = "setuptools";
14
15 src = fetchFromGitHub {
16 owner = "erfanoabdi";
17 repo = pname;
18 rev = version;
19 sha256 = "1X9gAux9w/mCEVmE3Yqvvq3kU7hu4iAFaZWNZZZxt3E=";
20 };
21
22 buildInputs = [ libgbinder ];
23
24 nativeBuildInputs = [
25 cython_0
26 pkg-config
27 ];
28
29 postPatch = ''
30 # Fix pkg-config name for cross-compilation
31 substituteInPlace setup.py --replace "pkg-config" "$PKG_CONFIG"
32 '';
33
34 setupPyGlobalFlags = [ "--cython" ];
35
36 meta = {
37 description = "Python bindings for libgbinder";
38 homepage = "https://github.com/erfanoabdi/gbinder-python";
39 license = lib.licenses.gpl3;
40 platforms = lib.platforms.linux;
41 maintainers = with lib.maintainers; [ mcaju ];
42 };
43}