{ stdenv , lib , fetchFromGitHub , cmake , openssl , srtp , usrsctp , plog , nlohmann_json , libnice }: stdenv.mkDerivation rec { pname = "libdatachannel"; version = "0.19.0-alpha.4"; src = fetchFromGitHub { owner = "paullouisageneau"; repo = "libdatachannel"; rev = "v${version}"; sha256 = "sha256-PRH0XfO+nr6KQfWmeV5S7VsWF6HxFB44DSrO1I9CI6g="; }; nativeBuildInputs = [ cmake ]; buildInputs = [ openssl srtp usrsctp plog nlohmann_json libnice ]; cmakeFlags = [ "-DPREFER_SYSTEM_LIB=ON" "-DUSE_NICE=ON" "-DNO_EXAMPLES=ON" "-DNO_TESTS=ON" # wants ICE/STUN server on the internet ]; meta = with lib; { description = "C/C++ WebRTC network library"; maintainers = with maintainers; [ lukegb ]; platforms = platforms.all; license = with licenses; [ mpl20 ]; }; }