anchor.diff: -{ stdenv, fetchFromGitHub, pkgconfig, cmake, git, doxygen, help2man, tecla
  +{ stdenv, lib, fetchFromGitHub, pkgconfig, cmake, git, doxygen, help2man, ncurses, tecla
   , libusb1, udev }:
   
   stdenv.mkDerivation rec {
  
positive.code:   };
  
    nativeBuildInputs = [ pkgconfig ];
    buildInputs = [ cmake git doxygen help2man tecla libusb1 udev ];
  
    # Fixup shebang
    prePatch = "patchShebangs host/utilities/bladeRF-cli/src/cmd/doc/generate.bash";
  
negative.code:   '';
  
    cmakeFlags = [
      "-DBUILD_DOCUMENTATION=ON"
    ] ++ lib.optionals stdenv.isLinux [
      "-DUDEV_RULES_PATH=etc/udev/rules.d"
      "-DINSTALL_UDEV_RULES=ON"
    ];
  
    hardeningDisable = [ "fortify" ];
  
    meta = with lib; {
      homepage = https://nuand.com/libbladeRF-doc;
      description = "Supporting library of the BladeRF SDR opensource hardware";
      license = licenses.lgpl21;
      maintainers = with maintainers; [ funfunctor ];
      platforms = platforms.unix;
    };
  }
  