about summary refs log tree commit diff
path: root/pkgs/applications/video
diff options
context:
space:
mode:
authorJörg Thalheim <Mic92@users.noreply.github.com>2019-01-19 12:45:14 +0000
committerGitHub <noreply@github.com>2019-01-19 12:45:14 +0000
commitdb804db878631c9e5a2a4178d10f9c46b500e34e (patch)
treee2268619a554e4d4ad6eb35f7372e0cde67338b5 /pkgs/applications/video
parented1a8277cede1f1b4844e251b9d603f0e0a0e6d5 (diff)
parentc18c25f0e9090eafb1ac2d935398131952d28974 (diff)
downloadnixlib-db804db878631c9e5a2a4178d10f9c46b500e34e.tar
nixlib-db804db878631c9e5a2a4178d10f9c46b500e34e.tar.gz
nixlib-db804db878631c9e5a2a4178d10f9c46b500e34e.tar.bz2
nixlib-db804db878631c9e5a2a4178d10f9c46b500e34e.tar.lz
nixlib-db804db878631c9e5a2a4178d10f9c46b500e34e.tar.xz
nixlib-db804db878631c9e5a2a4178d10f9c46b500e34e.tar.zst
nixlib-db804db878631c9e5a2a4178d10f9c46b500e34e.zip
Merge pull request #38964 from Moredread/wip/mediathekview
mediathekview: 9 -> 13.2.1
Diffstat (limited to 'pkgs/applications/video')
-rw-r--r--pkgs/applications/video/mediathekview/default.nix44
-rw-r--r--pkgs/applications/video/zdfmediathk/default.nix38
2 files changed, 22 insertions, 60 deletions
diff --git a/pkgs/applications/video/mediathekview/default.nix b/pkgs/applications/video/mediathekview/default.nix
index 93a8d2070542..34efffc21d72 100644
--- a/pkgs/applications/video/mediathekview/default.nix
+++ b/pkgs/applications/video/mediathekview/default.nix
@@ -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;
   };
 }
diff --git a/pkgs/applications/video/zdfmediathk/default.nix b/pkgs/applications/video/zdfmediathk/default.nix
deleted file mode 100644
index a875daf065e9..000000000000
--- a/pkgs/applications/video/zdfmediathk/default.nix
+++ /dev/null
@@ -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;
-  };
-
-}