From 13c5e150fd85aef2d6498f1bc75105b9c7f7ba48 Mon Sep 17 00:00:00 2001 From: Mike Gilbert Date: Wed, 29 Feb 2012 00:30:03 -0500 Subject: [PATCH] cmake: Fix ffmpeg detection code ffmpeg headers are supposed to be referenced as libavcodec/avcodec.h. Therefore, we actually need to find the path to the libavcodec directory, not avcodec.h. --- cmake/FindFFmpeg.cmake | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/cmake/FindFFmpeg.cmake b/cmake/FindFFmpeg.cmake index 9b2464e95..add7336ed 100644 --- a/cmake/FindFFmpeg.cmake +++ b/cmake/FindFFmpeg.cmake @@ -13,13 +13,11 @@ if (PKG_CONFIG_FOUND) endif ( PKG_CONFIG_FOUND ) # avcodec -find_path(AVCODEC_INCLUDE_DIR avcodec.h PATHS ${AVCODEC_INCLUDE_DIRS} - PATH_SUFFIXES libavcodec ) +find_path(AVCODEC_INCLUDE_DIR libavcodec/avcodec.h PATHS ${AVCODEC_INCLUDE_DIRS}) find_library(AVCODEC_LIBRARY avcodec PATHS ${AVCODEC_LIBRARY_DIRS}) # avutil -find_path(AVUTIL_INCLUDE_DIR avutil.h PATHS ${AVUTIL_INCLUDE_DIRS} - PATH_SUFFIXES libavutil ) +find_path(AVUTIL_INCLUDE_DIR libavutil/avutil.h PATHS ${AVUTIL_INCLUDE_DIRS}) find_library(AVUTIL_LIBRARY avutil PATHS ${AVUTIL_LIBRARY_DIRS}) if(AVCODEC_INCLUDE_DIR AND AVCODEC_LIBRARY)