Merge pull request #190692 from siriobalmelli-foss/add/tsduck

tsduck: init at 3.31-2761
This commit is contained in:
Jonas Heinrich 2022-09-16 13:37:46 +02:00 committed by GitHub
commit 594b981f70
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 85 additions and 0 deletions

View File

@ -0,0 +1,83 @@
{ lib
, stdenv
, fetchFromGitHub
, curl
, jdk
, libedit
, srt
}:
stdenv.mkDerivation rec {
pname = "tsduck";
version = "3.31-2761";
src = fetchFromGitHub {
owner = "tsduck";
repo = pname;
rev = "v${version}";
sha256 = "sha256-268TKCh3naebbw+sOQ6d4N/zl7UEVtc3l3flFAYHDU4=";
};
buildInputs = [
curl
libedit
srt
jdk
];
# remove tests which call out to https://tsduck.io/download/test/...
postPatch = ''
sed -i"" \
-e '/TSUNIT_TEST(testMasterPlaylist);/ d' \
-e '/TSUNIT_TEST(testMasterPlaylistWithAlternate);/ d' \
-e '/TSUNIT_TEST(testMediaPlaylist);/ d' \
src/utest/utestHLS.cpp
sed -i"" \
-e '/TSUNIT_TEST(testBetterSystemRandomGenerator);/ d' \
src/utest/utestSystemRandomGenerator.cpp
sed -i"" \
-e '/TSUNIT_ASSERT(request.downloadBinaryContent/ d' \
-e '/TSUNIT_ASSERT(!request.downloadBinaryContent/ d' \
-e '/TSUNIT_TEST(testGitHub);/ d' \
-e '/TSUNIT_TEST(testGoogle);/ d' \
-e '/TSUNIT_TEST(testNoRedirection);/ d' \
-e '/TSUNIT_TEST(testReadMeFile);/ d' \
src/utest/utestWebRequest.cpp
sed -i"" \
-e '/TSUNIT_TEST(testHomeDirectory);/ d' \
src/utest/utestSysUtils.cpp
'';
enableParallelBuilding = true;
makeFlags = [
"NODEKTEC=1"
"NOHIDES=1"
"NOPCSC=1"
"NORIST=1"
"NOVATEK=1"
] ++ installFlags;
checkTarget = "test";
doCheck = true;
installFlags = [
"SYSROOT=${placeholder "out"}"
"SYSPREFIX=/"
"USRLIBDIR=/lib"
];
installTargets = [
"install-tools"
"install-devel"
];
meta = with lib; {
description = "The MPEG Transport Stream Toolkit";
homepage = "https://github.com/tsduck/tsduck";
license = licenses.bsd2;
maintainers = with maintainers; [ siriobalmelli ];
platforms = platforms.all;
};
}

View File

@ -4713,6 +4713,8 @@ with pkgs;
replay-sorcery = callPackage ../tools/video/replay-sorcery { };
tsduck = callPackage ../tools/video/tsduck { };
ripasso-cursive = callPackage ../tools/security/ripasso/cursive.nix {
inherit (darwin.apple_sdk.frameworks) AppKit Security;
};