Merge pull request #38964 from Moredread/wip/mediathekview

mediathekview: 9 -> 13.2.1
This commit is contained in:
Jörg Thalheim 2019-01-19 12:45:14 +00:00 committed by GitHub
commit db804db878
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
4 changed files with 26 additions and 63 deletions

View File

@ -1,31 +1,31 @@
{ stdenv, fetchurl, jre, unzip }:
{ stdenv, fetchurl, makeWrapper, jre }:
stdenv.mkDerivation {
name = "mediathekview-9";
stdenv.mkDerivation rec {
version = "13.2.1";
name = "mediathekview-${version}";
src = fetchurl {
url = "mirror://sourceforge/zdfmediathk/MediathekView_9.zip";
sha256 = "1wff0igr33z9p1mjw7yvb6658smdwnp22dv8klz0y8qg116wx7a4";
url = "https://download.mediathekview.de/stabil/MediathekView-${version}.tar.gz";
sha256 = "11wg6klviig0h7pprfaygamsgqr7drqra2s4yxgfak6665033l2a";
};
unpackPhase = "true";
buildInputs = [ unzip ];
# Could use some more love
# Maybe we can also preconfigure locations for vlc and the others.
nativeBuildInputs = [ makeWrapper ];
installPhase = ''
mkdir -p $out/bin
mkdir -p $out/opt/mediathekview
cd $out/opt/mediathekview
unzip $src
find . -iname '*.exe' -delete
sed -i -e 's, java, ${jre}/bin/java,' MediathekView__Linux.sh
ln -s $out/opt/mediathekview/MediathekView__Linux.sh $out/bin/mediathekview
'';
mkdir -p $out/{lib,bin,share/mediathekview}
install -m644 MediathekView.jar $out/
install -m644 -t $out/lib lib/*
install -m755 bin/flv.sh $out/share/mediathekview
makeWrapper ${jre}/bin/java $out/bin/mediathek \
--add-flags "-cp '$out/lib/*' -jar $out/MediathekView.jar"
'';
meta = with stdenv.lib; {
homepage = http://zdfmediathk.sourceforge.net/;
license = stdenv.lib.licenses.gpl3;
maintainers = [ maintainers.chaoflow ];
platforms = platforms.linux; # also macOS and cygwin, but not investigated, yet
description = "Offers access to the Mediathek of different tv stations (ARD, ZDF, Arte, etc.)";
homepage = https://mediathekview.de/;
license = licenses.gpl3;
maintainers = with maintainers; [ chaoflow moredread ];
platforms = platforms.all;
};
}

View File

@ -1,38 +0,0 @@
{ stdenv, fetchurl, jre }:
with stdenv;
mkDerivation rec {
version = "10";
name = "zdfmediathk-${version}";
src = fetchurl {
url = "https://github.com/xaverW/MediathekView/archive/Version${version}.tar.gz";
sha256 = "12iyigqjslbn8rzym1mq1s0mvss7r97aiy6wfdrq5m0psarlcljw";
};
installPhase = ''
mkdir -p $out/{lib,bin,share/{doc,licenses}}
cd dist/
install -m644 MediathekView.jar $out/
install -m644 -t $out/lib lib/*
install -m755 bin/flv.sh $out/bin/
install -m644 -t $out/share/doc Anleitung/*.pdf
install -m644 -t $out/share/licenses Copyright/{*.*,_copyright}
bin="$out/bin/mediathek"
cat >> "$bin" << EOF
#!/bin/sh
exec ${jre}/bin/java -cp "$out/lib/*" -Xms128M -Xmx1G -jar "$out/MediathekView.jar" "\$@"
EOF
chmod +x "$bin"
'';
meta = with stdenv.lib; {
description = "Offers access to the Mediathek of different tv stations (ARD, ZDF, Arte, etc.)";
homepage = https://github.com/xaverW/MediathekView/;
license = licenses.gpl3;
maintainers = [ maintainers.flosse ];
platforms = platforms.all;
};
}

View File

@ -341,6 +341,7 @@ mapAliases ({
xlibs = xorg; # added 2015-09
xpraGtk3 = xpra; # added 2018-09-13
youtubeDL = youtube-dl; # added 2014-10-26
zdfmediathk = mediathekview; # added 2019-01-19
# TODO(ekleog): add wasm alias to ocamlPackages.wasm after 19.03
# branch-off

View File

@ -18145,7 +18145,9 @@ in
mediainfo-gui = callPackage ../applications/misc/mediainfo-gui { };
mediathekview = callPackage ../applications/video/mediathekview { };
# mediathekview needs JavaFX, which currently only is available inside OracleJRE
# we might be able to get rid of it, as soon as we have an OpenJRE with OpenJFX included
mediathekview = callPackage ../applications/video/mediathekview { jre = oraclejre; };
meteo = callPackage ../applications/networking/weather/meteo { };
@ -23099,8 +23101,6 @@ in
zap = callPackage ../tools/networking/zap { };
zdfmediathk = callPackage ../applications/video/zdfmediathk { };
zopfli = callPackage ../tools/compression/zopfli { };
myEnvFun = callPackage ../misc/my-env {