1{ lib
2, boost
3, buildPythonPackage
4, cmake
5, cryptography
6, fetchFromGitHub
7, git
8, pc-ble-driver
9, pythonAtLeast
10, pythonOlder
11, scikit-build
12, setuptools
13, swig
14, wrapt
15}:
16
17buildPythonPackage rec {
18 pname = "pc-ble-driver-py";
19 version = "0.17.0";
20
21 disabled = pythonOlder "3.7";
22
23 src = fetchFromGitHub {
24 owner = "NordicSemiconductor";
25 repo = "pc-ble-driver-py";
26 rev = "refs/tags/v${version}";
27 hash = "sha256-brC33ar2Jq3R2xdrklvVsQKf6pcnKwD25PO4TIvXgTg=";
28 };
29
30 nativeBuildInputs = [
31 cmake
32 swig
33 git
34 setuptools
35 scikit-build
36 ];
37
38 buildInputs = [
39 boost
40 pc-ble-driver
41 ];
42
43 propagatedBuildInputs = [
44 cryptography
45 wrapt
46 ];
47
48 dontUseCmakeConfigure = true;
49
50 # doCheck tries to write to the global python directory to install things
51 doCheck = false;
52
53 pythonImportsCheck = [
54 "pc_ble_driver_py"
55 ];
56
57 meta = with lib; {
58 description = "Bluetooth Low Energy nRF5 SoftDevice serialization";
59 homepage = "https://github.com/NordicSemiconductor/pc-ble-driver-py";
60 changelog = "https://github.com/NordicSemiconductor/pc-ble-driver-py/releases/tag/v${version}";
61 license = licenses.unfreeRedistributable;
62 maintainers = with maintainers; [ gebner ];
63 platforms = platforms.unix;
64 };
65}