diff -r 3ff8694d9e22 -r 1652c1d9adc8 CMakeLists.txt --- a/CMakeLists.txt Wed Mar 06 11:18:54 2013 +0100 +++ b/CMakeLists.txt Wed Mar 06 12:12:02 2013 +0100 @@ -22,7 +22,7 @@ #possible cmake configuration option(NOSERVER "Disable gameServer build [default: auto]" OFF) option(NOPNG "Disable screenshoot compression [default: auto]" OFF) -option(NOVIDEOREC "Disable video recording [default: auto]" OFF) +option(NOVIDEOREC "Disable video recording [default: off]" OFF) #set this to ON when 2.1.0 becomes more widespread (and only for linux) option(SYSTEM_PHYSFS "Use system physfs [default:off]" OFF) @@ -194,11 +194,6 @@ list(APPEND pascal_flags "-Ff~/Library/Frameworks") #set deployment target list(APPEND pascal_flags "-k-macosx_version_min" "-k${minimum_macosx_version}" "-XR${CMAKE_OSX_SYSROOT}") - - #silly libav that always brings in VideoDecoderAcceleration, avaible only from 10.6.3 - if(NOT NOVIDEOREC AND ${minimum_macosx_version} VERSION_LESS "10.6") - set(${WARNING} "Video recording support before OS X 10.6 is experimental") - endif() endif(APPLE) @@ -358,6 +353,15 @@ list(APPEND pascal_flags "-XLAphysfs=${physfs_output_name}" "-dPHYSFS_INTERNAL") endif() +if(NOT ${NOVIDEOREC}) + find_package(FFMPEG) + if(NOT ${FFMPEG_FOUND}) + message(FATAL_ERROR "Missing FFMPEG/Libav! Rerun cmake with -DNOVIDEOREC=on to disable video recording") + endif() +else() + set(FFMPEG_FOUND false) +endif() + # add_subdirectory(misc/libphyslayer)