2017-05-17 20:26:11 +01:00
|
|
|
{ mkDerivation, lib, fetchFromGitHub, extra-cmake-modules
|
2017-04-17 21:28:20 +01:00
|
|
|
, qtbase, qtmultimedia, qtquick1, qttools
|
2018-10-08 19:23:02 +01:00
|
|
|
, libGL, libX11
|
2020-09-26 08:36:14 +01:00
|
|
|
, libass, openal, ffmpeg, libuchardet
|
2017-04-17 21:28:20 +01:00
|
|
|
, alsaLib, libpulseaudio, libva
|
|
|
|
}:
|
|
|
|
|
2017-05-17 20:26:11 +01:00
|
|
|
with lib;
|
2017-04-17 21:28:20 +01:00
|
|
|
|
2017-05-17 20:26:11 +01:00
|
|
|
mkDerivation rec {
|
2019-08-15 13:41:18 +01:00
|
|
|
pname = "libqtav";
|
2020-09-26 08:36:14 +01:00
|
|
|
version = "git-2020-09-10";
|
2017-04-17 21:28:20 +01:00
|
|
|
|
2017-05-17 20:26:11 +01:00
|
|
|
nativeBuildInputs = [ extra-cmake-modules qttools ];
|
2017-10-19 02:49:33 +01:00
|
|
|
buildInputs = [
|
2017-04-17 21:28:20 +01:00
|
|
|
qtbase qtmultimedia qtquick1
|
2018-10-08 19:23:02 +01:00
|
|
|
libGL libX11
|
2020-09-26 08:36:14 +01:00
|
|
|
libass openal ffmpeg libuchardet
|
2017-04-17 21:28:20 +01:00
|
|
|
alsaLib libpulseaudio libva
|
|
|
|
];
|
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
2020-09-26 08:36:14 +01:00
|
|
|
sha256 = "0qwrk40dihkbwmm7krz6qaqyn9v3qdjnd2k9b4s3a67x4403pib3";
|
|
|
|
rev = "2a470d2a8d2fe22fae969bee5d594909a07b350a";
|
2017-04-17 21:28:20 +01:00
|
|
|
repo = "QtAV";
|
|
|
|
owner = "wang-bin";
|
|
|
|
fetchSubmodules = true;
|
|
|
|
};
|
|
|
|
|
2018-10-08 19:23:02 +01:00
|
|
|
# Make sure libqtav finds its libGL dependency at both link and run time
|
|
|
|
# by adding libGL to rpath. Not sure why it wasn't done automatically like
|
|
|
|
# the other libraries as `libGL` is part of our `buildInputs`.
|
2019-10-30 01:29:30 +00:00
|
|
|
NIX_CFLAGS_LINK = "-Wl,-rpath,${libGL}/lib";
|
2017-04-17 21:28:20 +01:00
|
|
|
|
|
|
|
preFixup = ''
|
|
|
|
mkdir -p "$out/bin"
|
|
|
|
cp -a "./bin/"* "$out/bin"
|
|
|
|
'';
|
|
|
|
|
2018-10-08 19:23:02 +01:00
|
|
|
stripDebugList = [ "lib" "libexec" "bin" "qml" ];
|
|
|
|
|
2017-04-17 21:28:20 +01:00
|
|
|
meta = {
|
2018-10-08 19:23:02 +01:00
|
|
|
description = "A multimedia playback framework based on Qt + FFmpeg";
|
2017-04-17 21:28:20 +01:00
|
|
|
#license = licenses.lgpl21; # For the libraries / headers only.
|
|
|
|
license = licenses.gpl3; # With the examples (under bin) and most likely some of the optional dependencies used.
|
2020-04-01 02:11:51 +01:00
|
|
|
homepage = "http://www.qtav.org/";
|
2017-04-17 21:28:20 +01:00
|
|
|
maintainers = [ maintainers.jraygauthier ];
|
|
|
|
platforms = platforms.linux;
|
|
|
|
};
|
|
|
|
}
|