1 { stdenv, lib, fetchFromGitHub, cmake, CoreServices }:
3 stdenv.mkDerivation rec {
5 version = "2020-12-R1";
7 src = fetchFromGitHub {
8 owner = "greatscottgadgets";
11 sha256 = "1byv8174xam7siakr1p0523x97wkh0fmwmq341sd3g70qr2g767d";
14 nativeBuildInputs = [ cmake ] ++ lib.optionals stdenv.isDarwin [ CoreServices ];
16 # https://github.com/greatscottgadgets/libbtbb/issues/63
18 substituteInPlace lib/libbtbb.pc.in \
19 --replace '$'{prefix}/@CMAKE_INSTALL_LIBDIR@ @CMAKE_INSTALL_FULL_LIBDIR@ \
20 --replace '$'{prefix}/@CMAKE_INSTALL_INCLUDEDIR@ @CMAKE_INSTALL_FULL_INCLUDEDIR@
24 description = "Bluetooth baseband decoding library";
25 homepage = "https://github.com/greatscottgadgets/libbtbb";
26 license = licenses.gpl2;
27 maintainers = with maintainers; [ oxzi ];