2021-04-05 08:44:05 +00:00
|
|
|
{ lib
|
|
|
|
, fetchFromGitHub
|
|
|
|
, mkDerivation
|
|
|
|
, stdenv
|
|
|
|
, Cocoa
|
|
|
|
, CoreAudio
|
|
|
|
, CoreFoundation
|
|
|
|
, MediaPlayer
|
|
|
|
, SDL2
|
|
|
|
, cmake
|
|
|
|
, libGL
|
|
|
|
, libX11
|
|
|
|
, libXrandr
|
|
|
|
, libvdpau
|
|
|
|
, mpv
|
|
|
|
, ninja
|
|
|
|
, pkg-config
|
|
|
|
, python3
|
|
|
|
, qtbase
|
|
|
|
, qtwayland
|
|
|
|
, qtwebchannel
|
|
|
|
, qtwebengine
|
|
|
|
, qtx11extras
|
2024-05-16 08:18:43 +00:00
|
|
|
, withDbus ? stdenv.hostPlatform.isLinux
|
2021-04-05 08:44:05 +00:00
|
|
|
}:
|
|
|
|
|
|
|
|
mkDerivation rec {
|
|
|
|
pname = "jellyfin-media-player";
|
2024-06-10 16:41:15 +00:00
|
|
|
version = "1.11.1";
|
2021-04-05 08:44:05 +00:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
2021-04-19 06:40:06 +00:00
|
|
|
owner = "jellyfin";
|
2021-04-05 08:44:05 +00:00
|
|
|
repo = "jellyfin-media-player";
|
|
|
|
rev = "v${version}";
|
2024-06-10 16:41:15 +00:00
|
|
|
sha256 = "sha256-Jsn4kWQzUaQI9MpbsLJr6JSJk9ZSnMEcrebQ2DYegSU=";
|
2021-04-05 08:44:05 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
patches = [
|
2021-04-20 06:19:18 +00:00
|
|
|
# disable update notifications since the end user can't simply download the release artifacts to update
|
|
|
|
./disable-update-notifications.patch
|
2021-04-05 08:44:05 +00:00
|
|
|
];
|
|
|
|
|
|
|
|
buildInputs = [
|
|
|
|
SDL2
|
|
|
|
libGL
|
|
|
|
libX11
|
|
|
|
libXrandr
|
|
|
|
libvdpau
|
|
|
|
mpv
|
|
|
|
qtbase
|
|
|
|
qtwebchannel
|
|
|
|
qtwebengine
|
|
|
|
qtx11extras
|
|
|
|
] ++ lib.optionals stdenv.hostPlatform.isLinux [
|
|
|
|
qtwayland
|
|
|
|
] ++ lib.optionals stdenv.hostPlatform.isDarwin [
|
|
|
|
Cocoa
|
|
|
|
CoreAudio
|
|
|
|
CoreFoundation
|
|
|
|
MediaPlayer
|
|
|
|
];
|
|
|
|
|
|
|
|
nativeBuildInputs = [
|
|
|
|
cmake
|
|
|
|
ninja
|
|
|
|
pkg-config
|
|
|
|
python3
|
|
|
|
];
|
|
|
|
|
|
|
|
cmakeFlags = [
|
|
|
|
"-DQTROOT=${qtbase}"
|
|
|
|
"-GNinja"
|
2022-07-15 07:38:42 +00:00
|
|
|
] ++ lib.optionals (!withDbus) [
|
|
|
|
"-DLINUX_X11POWER=ON"
|
2021-04-05 08:44:05 +00:00
|
|
|
];
|
|
|
|
|
|
|
|
postInstall = lib.optionalString stdenv.hostPlatform.isDarwin ''
|
|
|
|
mkdir -p $out/bin $out/Applications
|
|
|
|
mv "$out/Jellyfin Media Player.app" $out/Applications
|
|
|
|
ln -s "$out/Applications/Jellyfin Media Player.app/Contents/MacOS/Jellyfin Media Player" $out/bin/jellyfinmediaplayer
|
|
|
|
'';
|
|
|
|
|
|
|
|
meta = with lib; {
|
2021-04-19 06:40:06 +00:00
|
|
|
homepage = "https://github.com/jellyfin/jellyfin-media-player";
|
2021-04-05 08:44:05 +00:00
|
|
|
description = "Jellyfin Desktop Client based on Plex Media Player";
|
2021-04-21 06:50:05 +00:00
|
|
|
license = with licenses; [ gpl2Only mit ];
|
2024-09-14 20:25:10 +00:00
|
|
|
platforms = [ "aarch64-linux" "x86_64-linux" "aarch64-darwin" "x86_64-darwin" ];
|
2021-08-01 21:45:45 +00:00
|
|
|
maintainers = with maintainers; [ jojosch kranzes ];
|
2021-05-07 14:32:48 +00:00
|
|
|
mainProgram = "jellyfinmediaplayer";
|
2021-04-05 08:44:05 +00:00
|
|
|
};
|
|
|
|
}
|