From 6679dbbd60d2c04865411458b49a1d85eb99d461 Mon Sep 17 00:00:00 2001 From: Nikolay Amiantov Date: Fri, 19 May 2017 01:59:44 +0300 Subject: [PATCH] ffmpeg: fix arm build --- pkgs/development/libraries/ffmpeg/generic.nix | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/pkgs/development/libraries/ffmpeg/generic.nix b/pkgs/development/libraries/ffmpeg/generic.nix index 8c74abc5709..57ac086368f 100644 --- a/pkgs/development/libraries/ffmpeg/generic.nix +++ b/pkgs/development/libraries/ffmpeg/generic.nix @@ -55,6 +55,8 @@ let # Disable dependency that needs fixes before it will work on Darwin or Arm disDarwinOrArmFix = origArg: minVer: fixArg: if ((isDarwin || isArm) && reqMin minVer) then fixArg else origArg; + + vaapiSupport = reqMin "0.6" && ((isLinux || isFreeBSD) && !isArm); in assert openglSupport -> mesa != null; @@ -121,7 +123,7 @@ stdenv.mkDerivation rec { "--enable-libmp3lame" (ifMinVer "1.2" "--enable-iconv") "--enable-libtheora" - (ifMinVer "0.6" (enableFeature (isLinux || isFreeBSD) "vaapi")) + (ifMinVer "0.6" (enableFeature vaapiSupport "vaapi")) "--enable-vdpau" "--enable-libvorbis" (disDarwinOrArmFix (ifMinVer "0.6" "--enable-libvpx") "0.6" "--disable-libvpx") @@ -197,8 +199,7 @@ stdenv.mkDerivation rec { installFlags = [ "install-man" ]; passthru = { - vaapiSupport = if reqMin "0.6" && ((isLinux || isFreeBSD) && !isArm) then true else false; - inherit vdpauSupport; + inherit vaapiSupport vdpauSupport; }; meta = with stdenv.lib; {