nixpkgs/pkgs/applications/video/anilibria-winmaclinux/default.nix

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

96 lines
2 KiB
Nix
Raw Normal View History

2023-07-12 22:51:13 +02:00
{ mkDerivation
, lib
, fetchFromGitHub
, qmake
, qtbase
, qtquickcontrols2
, qtwebsockets
, qtmultimedia
, gst_all_1
, wrapQtAppsHook
, makeDesktopItem
, copyDesktopItems
, libvlc
2023-07-12 22:51:13 +02:00
}:
mkDerivation rec {
pname = "anilibria-winmaclinux";
version = "1.2.12";
2023-07-12 22:51:13 +02:00
src = fetchFromGitHub {
owner = "anilibria";
repo = "anilibria-winmaclinux";
rev = version;
sha256 = "sha256-J9MBnHrVnDaJ8Ykf/n8OkWKbK/JfMxorH9E+mKe3T8k=";
2023-07-12 22:51:13 +02:00
};
sourceRoot = "source/src";
qmakeFlags = [ "PREFIX=${placeholder "out"}" ];
patches = [
./0001-fix-installation-paths.patch
2023-07-12 22:51:13 +02:00
./0002-disable-version-check.patch
./0003-build-with-vlc.patch
2023-07-12 22:51:13 +02:00
];
preConfigure = ''
substituteInPlace AniLibria.pro \
--replace "\$\$PREFIX" '${placeholder "out"}' \
--replace '@VLC_PATH@' '${libvlc}/include'
2023-07-12 22:51:13 +02:00
'';
qtWrapperArgs = [
"--prefix GST_PLUGIN_PATH : ${(with gst_all_1; lib.makeSearchPathOutput "lib" "lib/gstreamer-1.0" [
gst-plugins-bad
gst-plugins-good
gst-plugins-base
gst-libav
gstreamer
])}"
];
nativeBuildInputs = [
qmake
wrapQtAppsHook
copyDesktopItems
];
buildInputs = [
qtbase
qtquickcontrols2
qtwebsockets
qtmultimedia
libvlc
2023-07-12 22:51:13 +02:00
] ++ (with gst_all_1; [
gst-plugins-bad
gst-plugins-good
gst-plugins-base
gst-libav
gstreamer
]);
desktopItems = [
(makeDesktopItem (rec {
name = "AniLibria";
desktopName = name;
icon = "anilibria";
comment = meta.description;
genericName = "AniLibria desktop client";
categories = [ "Qt" "AudioVideo" "Player" ];
keywords = [ "anime" ];
exec = name;
terminal = false;
}))
];
meta = with lib; {
homepage = "https://github.com/anilibria/anilibria-winmaclinux";
description = "AniLibria cross platform desktop client";
license = licenses.gpl3;
maintainers = with maintainers; [ _3JlOy-PYCCKUi ];
inherit (qtbase.meta) platforms;
mainProgram = "AniLibria";
};
}