From 14837a8277e4b751d8a8154b656321e40a5e34d4 Mon Sep 17 00:00:00 2001 From: geistesk Date: Tue, 4 Sep 2018 18:46:31 +0200 Subject: [PATCH] mpv: add cddaSupport-flag to play Audio CDs Introduced `cddaSupport` for `mpv` which defaults to false. By enabling it, `mpv` will be compiled with cdda support (`libcdio{,-paranoia}`) to play audio CDs. --- pkgs/applications/video/mpv/default.nix | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/pkgs/applications/video/mpv/default.nix b/pkgs/applications/video/mpv/default.nix index bb96ed372e48..9d843a3bfefb 100644 --- a/pkgs/applications/video/mpv/default.nix +++ b/pkgs/applications/video/mpv/default.nix @@ -15,6 +15,10 @@ , libXxf86vm ? null , libXrandr ? null +, cddaSupport ? false + , libcdio ? null + , libcdio-paranoia ? null + , alsaSupport ? true, alsaLib ? null , bluraySupport ? true, libbluray ? null , bs2bSupport ? true, libbs2b ? null @@ -51,6 +55,7 @@ assert archiveSupport -> available libarchive; assert bluraySupport -> available libbluray; assert bs2bSupport -> available libbs2b; assert cacaSupport -> available libcaca; +assert cddaSupport -> all available [libcdio libcdio-paranoia]; assert cmsSupport -> available lcms2; assert drmSupport -> available libdrm; assert dvdnavSupport -> available libdvdnav; @@ -116,6 +121,7 @@ in stdenv.mkDerivation rec { "--disable-build-date" # Purity "--disable-macos-cocoa-cb" # Disable whilst Swift isn't supported (enableFeature archiveSupport "libarchive") + (enableFeature cddaSupport "cdda") (enableFeature dvdnavSupport "dvdnav") (enableFeature dvdreadSupport "dvdread") (enableFeature openalSupport "openal") @@ -160,6 +166,7 @@ in stdenv.mkDerivation rec { ++ optional xvSupport libXv ++ optional youtubeSupport youtube-dl ++ optional stdenv.isDarwin libiconv + ++ optionals cddaSupport [ libcdio libcdio-paranoia ] ++ optionals dvdnavSupport [ libdvdnav libdvdnav.libdvdread ] ++ optionals waylandSupport [ wayland wayland-protocols libxkbcommon ] ++ optionals x11Support [ libX11 libXext libGLU_combined libXxf86vm libXrandr ]