Merge pull request #66684 from vbgl/mkvtoolnix-qt-mkDerivation

mkvtoolnix: use wrapQtApp
This commit is contained in:
worldofpeace 2019-08-18 17:58:06 -04:00 committed by GitHub
commit 27dbf754e3
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -4,9 +4,10 @@
, withGUI ? true
, qtbase ? null
, qtmultimedia ? null
, wrapQtAppsHook ? null
}:
assert withGUI -> qtbase != null && qtmultimedia != null;
assert withGUI -> qtbase != null && qtmultimedia != null && wrapQtAppsHook != null;
with stdenv.lib;
@ -30,7 +31,7 @@ stdenv.mkDerivation rec {
expat file xdg_utils boost libebml zlib fmt
libmatroska libogg libvorbis flac cmark
] ++ optional stdenv.isDarwin libiconv
++ optionals withGUI [ qtbase qtmultimedia ];
++ optionals withGUI [ qtbase qtmultimedia wrapQtAppsHook ];
preConfigure = "./autogen.sh; patchShebangs .";
buildPhase = "drake -j $NIX_BUILD_CORES";
@ -49,6 +50,11 @@ stdenv.mkDerivation rec {
(enableFeature withGUI "qt")
];
dontWrapQtApps = true;
postFixup = optionalString withGUI ''
wrapQtApp $out/bin/mkvtoolnix-gui
'';
meta = with stdenv.lib; {
description = "Cross-platform tools for Matroska";
homepage = http://www.bunkus.org/videotools/mkvtoolnix/;