CMakeLists: Fix find_package
call
Fixes #4959 Previously options for video dumper and audio decoder is separated, but I forgot to split this `find_package` call so that the other libraries won't be necessary when only using the audio decoder.
This commit is contained in:
parent
acf1fe5ee1
commit
977ccda30f
@ -209,7 +209,11 @@ if (ENABLE_FFMPEG)
|
|||||||
endif()
|
endif()
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
find_package(FFmpeg REQUIRED COMPONENTS avcodec avformat avutil swscale swresample)
|
if (ENABLE_FFMPEG_VIDEO_DUMPER)
|
||||||
|
find_package(FFmpeg REQUIRED COMPONENTS avcodec avformat avutil swscale swresample)
|
||||||
|
else()
|
||||||
|
find_package(FFmpeg REQUIRED COMPONENTS avcodec)
|
||||||
|
endif()
|
||||||
if ("${FFmpeg_avcodec_VERSION}" VERSION_LESS "57.48.101")
|
if ("${FFmpeg_avcodec_VERSION}" VERSION_LESS "57.48.101")
|
||||||
message(FATAL_ERROR "Found version for libavcodec is too low. The required version is at least 57.48.101 (included in FFmpeg 3.1 and later).")
|
message(FATAL_ERROR "Found version for libavcodec is too low. The required version is at least 57.48.101 (included in FFmpeg 3.1 and later).")
|
||||||
endif()
|
endif()
|
||||||
|
Loading…
Reference in New Issue
Block a user