mirror of
https://github.com/ilyakooo0/nixpkgs.git
synced 2024-10-04 11:37:19 +03:00
commit
0398f79c29
@ -1,26 +1,59 @@
|
||||
{ lib, fetchFromGitHub, cmake, git, swig, boost, udev, pc-ble-driver, pythonOlder
|
||||
, buildPythonPackage, enum34, wrapt, future, setuptools, scikit-build, pythonAtLeast }:
|
||||
{ lib
|
||||
, boost
|
||||
, buildPythonPackage
|
||||
, cmake
|
||||
, cryptography
|
||||
, fetchFromGitHub
|
||||
, git
|
||||
, pc-ble-driver
|
||||
, pythonAtLeast
|
||||
, pythonOlder
|
||||
, scikit-build
|
||||
, setuptools
|
||||
, swig
|
||||
, udev
|
||||
, wrapt
|
||||
}:
|
||||
|
||||
buildPythonPackage rec {
|
||||
pname = "pc-ble-driver-py";
|
||||
version = "0.15.0";
|
||||
disabled = pythonOlder "3.6" || pythonAtLeast "3.9";
|
||||
version = "0.16.1";
|
||||
|
||||
disabled = pythonOlder "3.7" || pythonAtLeast "3.10";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "NordicSemiconductor";
|
||||
repo = "pc-ble-driver-py";
|
||||
rev = version;
|
||||
sha256 = "1ckbsq9dwca8hpx9frf9xd80b4z4kn9j7jx94hza9bwzrh26x5ji";
|
||||
rev = "v${version}";
|
||||
sha256 = "0q2zag77drcjkjm0cbvy2sf6fq2a4yl5li1zv1xfwmy53ami9b5l";
|
||||
};
|
||||
|
||||
nativeBuildInputs = [
|
||||
cmake
|
||||
swig
|
||||
git
|
||||
setuptools
|
||||
scikit-build
|
||||
];
|
||||
|
||||
buildInputs = [
|
||||
boost
|
||||
pc-ble-driver
|
||||
];
|
||||
|
||||
propagatedBuildInputs = [
|
||||
cryptography
|
||||
wrapt
|
||||
];
|
||||
|
||||
dontUseCmakeConfigure = true;
|
||||
|
||||
# doCheck tries to write to the global python directory to install things
|
||||
doCheck = false;
|
||||
|
||||
nativeBuildInputs = [ cmake swig git setuptools scikit-build ];
|
||||
buildInputs = [ boost pc-ble-driver ];
|
||||
propagatedBuildInputs = [ enum34 wrapt future ];
|
||||
|
||||
dontUseCmakeConfigure = true;
|
||||
pythonImportsCheck = [
|
||||
"pc_ble_driver_py"
|
||||
];
|
||||
|
||||
meta = with lib; {
|
||||
description = "Bluetooth Low Energy nRF5 SoftDevice serialization";
|
||||
|
@ -1,8 +1,14 @@
|
||||
{ buildPythonPackage, isPy27, fetchFromGitHub, lib, ipaddress }:
|
||||
{ lib
|
||||
, buildPythonPackage
|
||||
, fetchFromGitHub
|
||||
, isPy27
|
||||
, pytestCheckHook
|
||||
}:
|
||||
|
||||
buildPythonPackage rec {
|
||||
pname = "piccata";
|
||||
version = "2.0.0";
|
||||
|
||||
disabled = isPy27;
|
||||
|
||||
src = fetchFromGitHub {
|
||||
@ -12,15 +18,23 @@ buildPythonPackage rec {
|
||||
sha256 = "0pn842jcf2czjks5dphivgp1s7wiifqiv93s0a89h0wxafd6pbsr";
|
||||
};
|
||||
|
||||
propagatedBuildInputs = [
|
||||
ipaddress
|
||||
checkInputs = [
|
||||
pytestCheckHook
|
||||
];
|
||||
|
||||
pythonImportsCheck = [ "piccata" ];
|
||||
disabledTests = [
|
||||
# No communication possible in the sandbox
|
||||
"test_client_server_communication"
|
||||
];
|
||||
|
||||
meta = {
|
||||
pythonImportsCheck = [
|
||||
"piccata"
|
||||
];
|
||||
|
||||
meta = with lib; {
|
||||
description = "Simple CoAP (RFC7252) toolkit";
|
||||
homepage = "https://github.com/NordicSemiconductor/piccata";
|
||||
maintainers = with lib.maintainers; [ gebner ];
|
||||
license = licenses.mit;
|
||||
maintainers = with maintainers; [ gebner ];
|
||||
};
|
||||
}
|
||||
|
@ -1,27 +1,33 @@
|
||||
{ lib, buildPythonPackage, fetchFromGitHub, isPy27
|
||||
, future, pyserial, ipaddress
|
||||
{ lib
|
||||
, buildPythonPackage
|
||||
, fetchFromGitHub
|
||||
, pyserial
|
||||
, pythonOlder
|
||||
}:
|
||||
|
||||
buildPythonPackage rec {
|
||||
pname = "pyspinel";
|
||||
version = "unstable-2020-06-19"; # no versioned release since 2018
|
||||
disabled = isPy27;
|
||||
version = "unstable-2021-08-19";
|
||||
|
||||
disabled = pythonOlder "3.7";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "openthread";
|
||||
repo = pname;
|
||||
rev = "e0bb3f8e6f49b593ab248a75de04a71626ae8101";
|
||||
sha256 = "0nfmdkgbhmkl82dfxjpwiiarxngm6a3fvdrzpaqp60a4b17pipqg";
|
||||
rev = "50d104e29eacd92d229f0b7179ec1067f5851c17";
|
||||
sha256 = "0s2r00zb909cq3dd28i91qbl0nz8cga3g98z84gq5jqkjpiy8269";
|
||||
};
|
||||
|
||||
propagatedBuildInputs = [
|
||||
future
|
||||
ipaddress
|
||||
pyserial
|
||||
];
|
||||
|
||||
# Tests are out-dated
|
||||
doCheck = false;
|
||||
pythonImportsCheck = [ "spinel" ];
|
||||
|
||||
pythonImportsCheck = [
|
||||
"spinel"
|
||||
];
|
||||
|
||||
meta = with lib; {
|
||||
description = "Interface to the OpenThread Network Co-Processor (NCP)";
|
||||
|
@ -1,20 +1,62 @@
|
||||
{ lib, python3Packages, fetchFromGitHub }:
|
||||
{ lib
|
||||
, stdenv
|
||||
, fetchFromGitHub
|
||||
, pkgs
|
||||
, python3
|
||||
, python3Packages
|
||||
}:
|
||||
let
|
||||
py = python3.override {
|
||||
packageOverrides = self: super: {
|
||||
|
||||
with python3Packages; buildPythonApplication rec {
|
||||
libusb1 = super.libusb1.overridePythonAttrs (oldAttrs: rec {
|
||||
version = "1.9.3";
|
||||
src = oldAttrs.src.override {
|
||||
inherit version;
|
||||
sha256 = "0j8p7jb7sibiiib18vyv3w5rrk0f4d2dl99bs18nwkq6pqvwxrk0";
|
||||
};
|
||||
|
||||
postPatch = ''
|
||||
substituteInPlace usb1/libusb1.py --replace \
|
||||
"ctypes.util.find_library(base_name)" \
|
||||
"'${pkgs.libusb1}/lib/libusb-1.0${stdenv.hostPlatform.extensions.sharedLibrary}'"
|
||||
'';
|
||||
});
|
||||
};
|
||||
};
|
||||
in
|
||||
with py.pkgs;
|
||||
|
||||
buildPythonApplication rec {
|
||||
pname = "nrfutil";
|
||||
version = "6.1";
|
||||
version = "6.1.3";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "NordicSemiconductor";
|
||||
repo = "pc-nrfutil";
|
||||
rev = "v${version}";
|
||||
sha256 = "0g43lf5jmk0qxb7r4h68wr38fli6pjjk67w8l2cpdm9rd8jz4lpn";
|
||||
sha256 = "1gpxjdcjn4rjvk649vpkh563c7lx3rrfvamazb1qjii1pxrvvqa7";
|
||||
};
|
||||
|
||||
propagatedBuildInputs = [ pc-ble-driver-py six pyserial enum34 click ecdsa
|
||||
protobuf tqdm piccata pyspinel intelhex pyyaml crcmod libusb1 ipaddress ];
|
||||
propagatedBuildInputs = [
|
||||
click
|
||||
crcmod
|
||||
ecdsa
|
||||
libusb1
|
||||
intelhex
|
||||
pc-ble-driver-py
|
||||
piccata
|
||||
protobuf
|
||||
pyserial
|
||||
pyspinel
|
||||
pyyaml
|
||||
tqdm
|
||||
];
|
||||
|
||||
checkInputs = [ nose behave ];
|
||||
checkInputs = [
|
||||
behave
|
||||
nose
|
||||
];
|
||||
|
||||
postPatch = ''
|
||||
mkdir test-reports
|
||||
|
Loading…
Reference in New Issue
Block a user