diff options
Diffstat (limited to 'Modules/FindAVIFile.cmake')
-rw-r--r-- | Modules/FindAVIFile.cmake | 20 |
1 files changed, 9 insertions, 11 deletions
diff --git a/Modules/FindAVIFile.cmake b/Modules/FindAVIFile.cmake index ff140f6..7272ba6 100644 --- a/Modules/FindAVIFile.cmake +++ b/Modules/FindAVIFile.cmake @@ -35,16 +35,14 @@ IF (UNIX) ENDIF (UNIX) -SET (AVIFILE_FOUND "NO") - -IF(AVIFILE_INCLUDE_DIR) - IF(AVIFILE_AVIPLAY_LIBRARY) - SET( AVIFILE_LIBRARIES ${AVIFILE_AVIPLAY_LIBRARY} ) - SET( AVIFILE_FOUND "YES" ) - SET( AVIFILE_DEFINITIONS "") - - ENDIF(AVIFILE_AVIPLAY_LIBRARY) -ENDIF(AVIFILE_INCLUDE_DIR) - +# handle the QUIETLY and REQUIRED arguments and set AVIFILE_FOUND to TRUE if +# all listed variables are TRUE +INCLUDE(FindPackageHandleStandardArgs) +FIND_PACKAGE_HANDLE_STANDARD_ARGS(AVIFile DEFAULT_MSG AVIFILE_INCLUDE_DIR AVIFILE_AVIPLAY_LIBRARY) + +IF (AVIFILE_FOUND) + SET(AVIFILE_LIBRARIES ${AVIFILE_AVIPLAY_LIBRARY}) + SET(AVIFILE_DEFINITIONS "") +ENDIF() MARK_AS_ADVANCED(AVIFILE_INCLUDE_DIR AVIFILE_AVIPLAY_LIBRARY) |