mirror of
https://github.com/mpv-player/mpv
synced 2025-02-19 22:36:55 +00:00
configure: abort if FFmpeg libraries are not found
Abort if FFmpeg libraries are not found unless --disable-ffmpeg was explicitly specified. Note that even if you disable FFmpeg, libavutil and libswscale are still required and you'll need to add linker flags for them manually; I didn't try to clean up that case (few people will want to do that). Also fix the fallback test used if pkg-config doesn't find the libraries: fix wrong header name and drop forced -lavcore which isn't present in all FFmpeg versions. This shouldn't make a difference for normal use since the pkg-config test should succeed if the libraries are available.
This commit is contained in:
parent
e1a8392cae
commit
b7e2899655
6
configure
vendored
6
configure
vendored
@ -6077,9 +6077,11 @@ if test "$ffmpeg" = auto ; then
|
||||
extra_ldflags="$extra_ldflags $_ld_tmp"
|
||||
extra_cflags="$extra_cflags $inc_ffmpeg"
|
||||
ffmpeg=yes
|
||||
elif header_check libavcore/avutil.h -lpostproc -lswscale -lavformat -lavcodec -lavutil $_ld_lm ; then
|
||||
extra_ldflags="$extra_ldflags -lpostproc -lswscale -lavformat -lavcodec -lavutil -lavcore"
|
||||
elif header_check libavutil/avutil.h -lpostproc -lswscale -lavformat -lavcodec -lavutil $_ld_lm ; then
|
||||
extra_ldflags="$extra_ldflags -lpostproc -lswscale -lavformat -lavcodec -lavutil"
|
||||
ffmpeg=yes
|
||||
else
|
||||
die "Unable to find development files for some of the FFmpeg libraries above. Aborting. If you really mean to compile without FFmpeg support use --disable-ffmpeg."
|
||||
fi
|
||||
fi
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user