#and search the path which contain the libname/header.h (usefull for new version)
#Then we need to include ${FFMPEG_libname_INCLUDE_DIRS} (in old version case, use by ffmpeg header and osg plugin code)
-# (in new version case, use by ffmpeg header)
+# (in new version case, use by ffmpeg header)
#and ${FFMPEG_libname_INCLUDE_DIRS/libname} (in new version case, use by osg plugin code)
# old version of ffmpeg put header in $prefix/include/[ffmpeg]
# so try to find header in include directory
FIND_PATH(FFMPEG_${varname}_INCLUDE_DIRS ${headername}
- PATHS
+ HINTS
${FFMPEG_ROOT}/include
$ENV{FFMPEG_DIR}/include
$ENV{OSGDIR}/include
$ENV{OSG_ROOT}/include
+ PATHS
~/Library/Frameworks
/Library/Frameworks
/usr/local/include
# so try to find lib${shortname}/header in include directory
IF(NOT FFMPEG_${varname}_INCLUDE_DIRS)
FIND_PATH(FFMPEG_${varname}_INCLUDE_DIRS lib${shortname}/${headername}
+ HINTS
${FFMPEG_ROOT}/include
$ENV{FFMPEG_DIR}/include
$ENV{OSGDIR}/include
$ENV{OSG_ROOT}/include
+ PATHS
~/Library/Frameworks
/Library/Frameworks
/usr/local/include
FIND_LIBRARY(FFMPEG_${varname}_LIBRARIES
NAMES ${shortname}
- PATHS
+ HINTS
${FFMPEG_ROOT}/lib
$ENV{FFMPEG_DIR}/lib
$ENV{OSGDIR}/lib
$ENV{OSG_ROOT}/lib
+ PATHS
~/Library/Frameworks
/Library/Frameworks
/usr/local/lib