1
0
Fork 1
mirror of https://github.com/NixOS/nixpkgs.git synced 2024-12-04 19:45:54 +00:00
nixpkgs/pkgs/applications/video/cmplayer/default.nix

84 lines
2.2 KiB
Nix
Raw Normal View History

2014-09-18 02:59:50 +01:00
{ stdenv, fetchurl, fetchpatch, pkgconfig, python2, perl
, libX11, libxcb, qt5, mesa
, ffmpeg
, libchardet
, mpg123
, libass
, libdvdread
, libdvdnav
, icu
, libquvi
, alsaLib
, libvdpau, libva
, libbluray
, jackSupport ? false, jack ? null
, portaudioSupport ? false, portaudio ? null
, pulseSupport ? true, pulseaudio ? null
, cddaSupport ? false, libcdda ? null
}:
assert jackSupport -> jack != null;
assert portaudioSupport -> portaudio != null;
assert pulseSupport -> pulseaudio != null;
assert cddaSupport -> libcdda != null;
stdenv.mkDerivation rec {
name = "cmplayer-${version}";
version = "0.8.16";
src = fetchurl {
url = "https://github.com/xylosper/cmplayer/releases/download/v${version}/${name}-source.tar.gz";
sha256 = "1yppp0jbq3mwa7vq4sjmm2lsqnfcv4n7cjap50gc2bavq7qynr85";
};
2014-09-19 23:27:57 +01:00
patches = [ ./fix-gcc48.patch ];
2014-09-18 02:59:50 +01:00
buildInputs = with stdenv.lib;
[ libX11 libxcb qt5 mesa
ffmpeg
libchardet
mpg123
libass
libdvdread
libdvdnav
icu
libquvi
alsaLib
libvdpau
libva
libbluray
]
++ optional jackSupport jack
++ optional portaudioSupport portaudio
++ optional pulseSupport pulseaudio
++ optional cddaSupport libcdda
;
2014-10-02 09:22:47 +01:00
preConfigure = ''
patchShebangs ./configure
patchShebangs src/mpv/waf
'';
2014-09-18 02:59:50 +01:00
configureFlags = with stdenv.lib;
[ "--qmake=qmake" ]
++ optional jackSupport "--enable-jack"
++ optional portaudioSupport "--enable-portaudio"
++ optional pulseSupport "--enable-pulseaudio"
++ optional cddaSupport "--enable-cdda"
;
preBuild = "patchShebangs ./build-mpv";
nativeBuildInputs = [ pkgconfig python2 perl ];
enableParallelBuilding = true;
meta = with stdenv.lib; {
description = "Powerful and easy-to-use multimedia player";
homepage = http://cmplayer.github.io;
license = licenses.gpl2Plus;
maintainers = [ maintainers.abbradar ];
platforms = platforms.linux;
};
}