Commit ac2e4b77 authored by Faustino Osuna's avatar Faustino Osuna

cmake/FindFFmpeg.cmake: Add sub library's CFLAGS to FFmpeg_CFLAGS.

parent d68d15e5
......@@ -19,6 +19,8 @@ if (NOT FFmpeg_SEARCHED)
foreach (library ffmpeg avcodec avformat avutil postproc swscale)
find_library( ${library}_LIBRARY ${library} )
if (${library}_LIBRARY)
pkg_check_modules(${library}_LIBRARY lib${library})
set(FFmpeg_CFLAGS "${FFmpeg_CFLAGS} ${${library}_LIBRARY_CFLAGS}")
set(FFmpeg_LIBRARIES "${library};${FFmpeg_LIBRARIES}")
set(FFmpeg_FOUND TRUE CACHE INTERNAL "")
endif (${library}_LIBRARY)
......@@ -26,6 +28,8 @@ if (NOT FFmpeg_SEARCHED)
foreach (library a52 faac lame z png mp3lame twolame)
find_library( ${library}_LIBRARY ${library} )
if (${library}_LIBRARY)
pkg_check_modules(${library}_LIBRARY lib${library})
set(FFmpeg_CFLAGS "${FFmpeg_CFLAGS} ${${library}_LIBRARY_CFLAGS}")
set(FFmpeg_LIBRARIES "${library};${FFmpeg_LIBRARIES}")
endif (${library}_LIBRARY)
endforeach (library)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment