nixpkgs-suyu/pkgs/development/libraries/libbladeRF/default.nix

41 lines
1.1 KiB
Nix
Raw Normal View History

2015-07-02 16:25:24 +02:00
{ stdenv, fetchFromGitHub, pkgconfig, cmake, git, doxygen, help2man, tecla
, libusb1, udev }:
stdenv.mkDerivation rec {
2018-01-12 11:43:56 +01:00
version = "1.9.0";
name = "libbladeRF-v${version}";
2015-07-02 16:25:24 +02:00
src = fetchFromGitHub {
owner = "Nuand";
repo = "bladeRF";
rev = "libbladeRF_v${version}";
2018-01-12 11:43:56 +01:00
sha256 = "0frvphp4xxdxwzmi94b0asl7b891sd3fk8iw9kfk8h6f3cdhj8xa";
};
nativeBuildInputs = [ pkgconfig ];
buildInputs = [ cmake git doxygen help2man tecla libusb1 udev ];
# Fixup shebang
prePatch = "patchShebangs host/utilities/bladeRF-cli/src/cmd/doc/generate.bash";
# Let us avoid nettools as a dependency.
patchPhase = ''
sed -i 's/$(hostname)/hostname/' host/utilities/bladeRF-cli/src/cmd/doc/generate.bash
'';
cmakeFlags = [
"-DCMAKE_BUILD_TYPE=Debug"
"-DUDEV_RULES_PATH=etc/udev/rules.d"
"-DINSTALL_UDEV_RULES=ON"
"-DBUILD_DOCUMENTATION=ON"
];
2015-07-02 16:25:24 +02:00
meta = with stdenv.lib; {
homepage = https://www.nuand.com/;
description = "Supporting library of the BladeRF SDR opensource hardware";
2015-07-02 16:25:24 +02:00
license = licenses.lgpl21;
maintainers = with maintainers; [ funfunctor ];
2018-01-12 11:43:56 +01:00
platforms = with platforms; linux;
};
}