From 63b3cf669bdf9a67768ea563da865477a34c2672 Mon Sep 17 00:00:00 2001 From: Sterling Stein Date: Fri, 25 Apr 2014 20:13:12 -0700 Subject: [PATCH] Add subtitle option for ffmpeg. --- pkgs/development/libraries/ffmpeg/2.x.nix | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/pkgs/development/libraries/ffmpeg/2.x.nix b/pkgs/development/libraries/ffmpeg/2.x.nix index 919972efb3c4..7ffc3a077eff 100644 --- a/pkgs/development/libraries/ffmpeg/2.x.nix +++ b/pkgs/development/libraries/ffmpeg/2.x.nix @@ -1,5 +1,5 @@ { stdenv, fetchurl, config, pkgconfig, yasm, zlib, bzip2, alsaLib, texinfo, perl -, lame, speex, libtheora, libvorbis, libvpx, x264, xvidcore, libopus +, lame, speex, libass, libtheora, libvorbis, libvpx, x264, xvidcore, libopus , libvdpau, libva, faac, libdc1394, libXext, libXfixes, SDL , freetype, fontconfig, fdk_aac, gnutls }: @@ -12,6 +12,7 @@ stdenv.mkDerivation rec { sha256 = "153kfk8rzrfxx930rrk417b2m695dvy47v4hci3nd49iggx9jzz1"; }; + subtitleSupport = config.ffmpeg.subtitle or true; mp3Support = config.ffmpeg.mp3 or true; speexSupport = config.ffmpeg.speex or true; theoraSupport = config.ffmpeg.theora or true; @@ -41,6 +42,7 @@ stdenv.mkDerivation rec { "--enable-avresample" "--enable-runtime-cpudetect" ] + ++ stdenv.lib.optional subtitleSupport "--enable-libass" ++ stdenv.lib.optional mp3Support "--enable-libmp3lame" ++ stdenv.lib.optional speexSupport "--enable-libspeex" ++ stdenv.lib.optional theoraSupport "--enable-libtheora" @@ -59,6 +61,7 @@ stdenv.mkDerivation rec { ++ stdenv.lib.optional gnutlsSupport "--enable-gnutls"; buildInputs = [ pkgconfig lame yasm zlib bzip2 alsaLib texinfo perl ] + ++ stdenv.lib.optional subtitleSupport libass ++ stdenv.lib.optional mp3Support lame ++ stdenv.lib.optional speexSupport speex ++ stdenv.lib.optional theoraSupport libtheora