Clone of https://github.com/NixOS/nixpkgs.git (to stress-test knotserver)
1{ 2 lib, 3 stdenv, 4 fetchFromGitHub, 5 cmake, 6 pkg-config, 7 hackrf, 8 soapysdr, 9}: 10 11let 12 version = "0.3.4"; 13 14in 15stdenv.mkDerivation { 16 pname = "soapyhackrf"; 17 inherit version; 18 19 src = fetchFromGitHub { 20 owner = "pothosware"; 21 repo = "SoapyHackRF"; 22 rev = "soapy-hackrf-${version}"; 23 sha256 = "sha256-fzPYHJAPX8FkFxPXpLlUagTd/NoamRX0YnxHwkbV1nI="; 24 }; 25 26 nativeBuildInputs = [ 27 cmake 28 pkg-config 29 ]; 30 buildInputs = [ 31 hackrf 32 soapysdr 33 ]; 34 35 cmakeFlags = [ "-DSoapySDR_DIR=${soapysdr}/share/cmake/SoapySDR/" ]; 36 37 meta = with lib; { 38 homepage = "https://github.com/pothosware/SoapyHackRF"; 39 description = "SoapySDR plugin for HackRF devices"; 40 license = licenses.mit; 41 maintainers = with maintainers; [ markuskowa ]; 42 platforms = platforms.unix; 43 }; 44}