Skip to content

Commit

Permalink
Merge pull request #5059 from Orphis/ffmpeg_windows
Browse files Browse the repository at this point in the history
cmake: Find bundled ffmpeg even if you have pkg-config on Win32
  • Loading branch information
CrossVR committed Mar 10, 2017
2 parents ae0f9c2 + d2119d3 commit 9b5a0b3
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion CMake/CheckLib.cmake
Expand Up @@ -60,7 +60,9 @@ macro(check_libav)
if(PKG_CONFIG_FOUND)
pkg_check_modules(LIBAV libavcodec>=54.35.0 libavformat>=54.20.4
libswscale>=2.1.1 libavutil>=52.3.0)
else()
endif()

if(NOT LIBAV_FOUND)
if(WIN32)
add_library(avcodec STATIC IMPORTED)
set_target_properties(avcodec PROPERTIES
Expand Down Expand Up @@ -114,6 +116,7 @@ macro(check_libav)
unset(CMAKE_REQUIRED_LIBRARIES)
endif()
endif()

if(LIBAV_FOUND)
message(STATUS "libav/ffmpeg found, enabling AVI frame dumps")
add_definitions(-DHAVE_LIBAV)
Expand Down

0 comments on commit 9b5a0b3

Please sign in to comment.