1{ 2 ahocorapy, 3 buildPythonPackage, 4 construct, 5 fetchFromGitHub, 6 lib, 7 pybluez, 8 pytestCheckHook, 9 setuptools, 10 stdenv, 11}: 12 13buildPythonPackage rec { 14 pname = "beacontools"; 15 version = "2.1.0"; 16 pyproject = true; 17 18 src = fetchFromGitHub { 19 owner = "citruz"; 20 repo = "beacontools"; 21 tag = "v${version}"; 22 hash = "sha256-3a/HDssOqIfReSijRvmiXwuZjvWLJfDaDyUdA2vv/jA="; 23 }; 24 25 build-system = [ setuptools ]; 26 27 pythonRelaxDeps = [ 28 "ahocorapy" 29 ]; 30 31 dependencies = [ 32 ahocorapy 33 construct 34 ]; 35 36 optional-dependencies = { 37 scan = lib.optionals stdenv.hostPlatform.isLinux [ pybluez ]; 38 }; 39 40 pythonImportsCheck = [ "beacontools" ]; 41 42 nativeCheckInputs = [ 43 pytestCheckHook 44 ]; 45 46 meta = { 47 changelog = "https://github.com/citruz/beacontools/releases/tag/${src.tag}"; 48 description = "Python library for working with various types of Bluetooth LE Beacons"; 49 homepage = "https://github.com/citruz/beacontools"; 50 license = lib.licenses.mit; 51 maintainers = with lib.maintainers; [ dotlambda ]; 52 }; 53}