pc-ble-driver-py: 0.11.4 -> 0.14.2
This commit is contained in:
parent
e1a1b974ed
commit
d82b7b8690
@ -1,45 +1,25 @@
|
|||||||
{ stdenv, buildPythonPackage, fetchpatch, fetchFromGitHub,
|
{ stdenv, fetchFromGitHub, cmake, git, swig, boost, udev, pc-ble-driver
|
||||||
python, cmake, git, swig, boost, udev,
|
, buildPythonPackage, enum34, wrapt, future, setuptools, scikit-build }:
|
||||||
setuptools, enum34, wrapt, future }:
|
|
||||||
|
|
||||||
buildPythonPackage rec {
|
buildPythonPackage rec {
|
||||||
pname = "pc-ble-driver-py";
|
pname = "pc-ble-driver-py";
|
||||||
version = "0.11.4";
|
version = "0.14.2";
|
||||||
disabled = python.isPy3k;
|
|
||||||
|
|
||||||
src = fetchFromGitHub {
|
src = fetchFromGitHub {
|
||||||
owner = "NordicSemiconductor";
|
owner = "NordicSemiconductor";
|
||||||
repo = "pc-ble-driver-py";
|
repo = "pc-ble-driver-py";
|
||||||
rev = "v${version}";
|
rev = "v${version}";
|
||||||
fetchSubmodules = true;
|
sha256 = "1zbi3v4jmgq1a3ml34dq48y1hinw2008vwqn30l09r5vqvdgnj8m";
|
||||||
sha256 = "0lgmcnrlcivmawmlcwnn4pdp6afdbnf3fyfgq22xzs6v72m9gp81";
|
|
||||||
};
|
};
|
||||||
|
|
||||||
nativeBuildInputs = [ cmake swig git setuptools ];
|
# doCheck tries to write to the global python directory to install things
|
||||||
buildInputs = [ boost udev ];
|
doCheck = false;
|
||||||
|
|
||||||
|
nativeBuildInputs = [ cmake swig git setuptools scikit-build ];
|
||||||
|
buildInputs = [ boost udev pc-ble-driver ];
|
||||||
propagatedBuildInputs = [ enum34 wrapt future ];
|
propagatedBuildInputs = [ enum34 wrapt future ];
|
||||||
|
|
||||||
patches = [
|
dontUseCmakeConfigure = true;
|
||||||
# build system expects case-insensitive file system
|
|
||||||
(fetchpatch {
|
|
||||||
url = "https://patch-diff.githubusercontent.com/raw/NordicSemiconductor/pc-ble-driver-py/pull/84.patch";
|
|
||||||
sha256 = "0ibx5g2bndr5h9sfnx51bk9b62q4jvpdwhxadbnj3da8kvcz13cy";
|
|
||||||
})
|
|
||||||
];
|
|
||||||
|
|
||||||
postPatch = ''
|
|
||||||
# do not force static linking of boost
|
|
||||||
sed -i /Boost_USE_STATIC_LIBS/d pc-ble-driver/cmake/*.cmake
|
|
||||||
|
|
||||||
cd python
|
|
||||||
'';
|
|
||||||
|
|
||||||
preBuild = ''
|
|
||||||
pushd ../build
|
|
||||||
cmake ..
|
|
||||||
make -j $NIX_BUILD_CORES
|
|
||||||
popd
|
|
||||||
'';
|
|
||||||
|
|
||||||
meta = with stdenv.lib; {
|
meta = with stdenv.lib; {
|
||||||
description = "Bluetooth Low Energy nRF5 SoftDevice serialization";
|
description = "Bluetooth Low Energy nRF5 SoftDevice serialization";
|
||||||
|
Loading…
Reference in New Issue
Block a user