[FFmpeg-devel] [PATCH] configure: Allow users to disable all hwaccel libraries

Mark Thompson sw at jkqxz.net
Sun Dec 10 19:14:22 EET 2017


On 07/12/17 09:31, Gyan Doshi wrote:
> On 12/7/2017 12:59 PM, Tobias Rapp wrote:
>>
>> Why not add the HWACCEL_AUTODETECT_LIBRARY_LIST to --disable-hwaccels?
> 
> That is a better choice but there wasn't a bespoke case for '--disable-hwaccels', so originally ignored that possibility. Added it in attached (new) patch.
> 
> Either one - this or original patch - works for me.
> 
> From f5c02c73ad3560a2173611ec1e76a460cf70d944 Mon Sep 17 00:00:00 2001
> From: Gyan Doshi <gyandoshi at gmail.com>
> Date: Thu, 7 Dec 2017 14:44:01 +0530
> Subject: [PATCH] configure - extend disable_hwaccels to disable autodetected
>  hwaccel libs
> 
> ---
>  configure | 5 ++++-
>  1 file changed, 4 insertions(+), 1 deletion(-)
> 
> diff --git a/configure b/configure
> index d05388638d..77812759fd 100755
> --- a/configure
> +++ b/configure
> @@ -159,7 +159,7 @@ Individual component options:
>    --disable-decoders       disable all decoders
>    --disable-hwaccel=NAME   disable hwaccel NAME
>    --enable-hwaccel=NAME    enable hwaccel NAME
> -  --disable-hwaccels       disable all hwaccels
> +  --disable-hwaccels       disable all hwaccels and autodetected hwaccel libs
>    --disable-muxer=NAME     disable muxer NAME
>    --enable-muxer=NAME      enable muxer NAME
>    --disable-muxers         disable all muxers
> @@ -3630,6 +3630,9 @@ for opt do
>          --extra-libs=*)
>              add_extralibs $optval
>          ;;
> +        --disable-hwaccels)
> +            disable $HWACCEL_LIST $HWACCEL_AUTODETECT_LIBRARY_LIST
> +        ;;
>          --disable-devices)
>              disable $INDEV_LIST $OUTDEV_LIST
>          ;;
> -- 
> 2.11.1.windows.1

The --disable-foos options consistently disable all foos, I don't think it should magically do something else as well.  This is also confusing the internal concept of hwaccels (AVHWAccel) with other things providing access to hardware features (e.g. you are making it disable AMF and V4L2 M2M, which are not hwaccels).

Can you explain what you actually want to achieve here?  It sounds more like you want --disable-autodetect (hardware libraries are not the only ones which can give surprise dependencies).

- Mark


More information about the ffmpeg-devel mailing list