Fix errors in cmake files.
This commit is contained in:
parent
8630d859d5
commit
4e7f4dd636
@ -1,57 +1,79 @@
|
|||||||
#
|
#
|
||||||
# Try to find OpenEXR's libraries, and include path.
|
# Try to find OpenEXR's libraries, and include path.
|
||||||
# Once done this will define:
|
# Once done this will define:
|
||||||
#
|
#
|
||||||
# OPENEXR_FOUND = OpenEXR found.
|
# OPENEXR_FOUND = OpenEXR found.
|
||||||
# OPENEXR_INCLUDE_PATH = OpenEXR include directory.
|
# OPENEXR_INCLUDE_PATHS = OpenEXR include directories.
|
||||||
# OPENEXR_LIBRARIES = libraries that are needed to use OpenEXR.
|
# OPENEXR_LIBRARIES = libraries that are needed to use OpenEXR.
|
||||||
#
|
#
|
||||||
|
|
||||||
|
INCLUDE(FindZLIB)
|
||||||
IF (WIN32)
|
|
||||||
ELSE (WIN32)
|
|
||||||
|
IF(ZLIB_FOUND)
|
||||||
FIND_PATH(OPENEXR_INCLUDE_PATH ImfRgbaFile.h
|
|
||||||
/usr/include
|
SET(LIBRARY_PATHS
|
||||||
/usr/local/include
|
/usr/lib
|
||||||
/usr/include/OpenEXR
|
/usr/local/lib
|
||||||
/usr/local/include/OpenEXR)
|
/sw/lib
|
||||||
|
/opt/local/lib
|
||||||
FIND_LIBRARY(OPENEXR_HALF_LIBRARY
|
$ENV{PROGRAM_FILES}/OpenEXR/lib/static)
|
||||||
NAMES Half
|
|
||||||
PATHS
|
FIND_PATH(OPENEXR_INCLUDE_PATH ImfRgbaFile.h
|
||||||
/usr/lib
|
PATH_SUFFIXES OpenEXR
|
||||||
/usr/local/lib)
|
/usr/include
|
||||||
|
/usr/local/include
|
||||||
FIND_LIBRARY(OPENEXR_IEX_LIBRARY
|
/sw/include
|
||||||
NAMES Iex
|
/opt/local/include)
|
||||||
PATHS
|
|
||||||
/usr/lib
|
FIND_LIBRARY(OPENEXR_HALF_LIBRARY
|
||||||
/usr/local/lib)
|
NAMES Half
|
||||||
|
PATHS ${LIBRARY_PATHS})
|
||||||
FIND_LIBRARY(OPENEXR_IMATH_LIBRARY
|
|
||||||
NAMES Imath
|
FIND_LIBRARY(OPENEXR_IEX_LIBRARY
|
||||||
PATHS
|
NAMES Iex
|
||||||
/usr/lib
|
PATHS ${LIBRARY_PATHS})
|
||||||
/usr/local/lib)
|
|
||||||
|
FIND_LIBRARY(OPENEXR_IMATH_LIBRARY
|
||||||
FIND_LIBRARY(OPENEXR_ILMIMF_LIBRARY
|
NAMES Imath
|
||||||
NAMES IlmImf
|
PATHS ${LIBRARY_PATHS})
|
||||||
PATHS
|
|
||||||
/usr/lib
|
FIND_LIBRARY(OPENEXR_ILMIMF_LIBRARY
|
||||||
/usr/local/lib)
|
NAMES IlmImf
|
||||||
|
PATHS ${LIBRARY_PATHS})
|
||||||
ENDIF (WIN32)
|
|
||||||
|
FIND_LIBRARY(OPENEXR_ILMTHREAD_LIBRARY
|
||||||
IF (OPENEXR_INCLUDE_PATH AND OPENEXR_IMATH_LIBRARY AND OPENEXR_ILMIMF_LIBRARY AND OPENEXR_IEX_LIBRARY AND OPENEXR_HALF_LIBRARY)
|
NAMES IlmThread
|
||||||
SET(OPENEXR_FOUND TRUE)
|
PATHS ${LIBRARY_PATHS})
|
||||||
SET(OPENEXR_LIBRARIES ${OPENEXR_IMATH_LIBRARY} ${OPENEXR_ILMIMF_LIBRARY} ${OPENEXR_IEX_LIBRARY} ${OPENEXR_HALF_LIBRARY} CACHE STRING "The libraries needed to use OpenEXR")
|
|
||||||
ENDIF (OPENEXR_INCLUDE_PATH AND OPENEXR_IMATH_LIBRARY AND OPENEXR_ILMIMF_LIBRARY AND OPENEXR_IEX_LIBRARY AND OPENEXR_HALF_LIBRARY)
|
ENDIF(ZLIB_FOUND)
|
||||||
|
|
||||||
MARK_AS_ADVANCED(
|
#MESSAGE(STATUS ${OPENEXR_IMATH_LIBRARY} ${OPENEXR_ILMIMF_LIBRARY} ${OPENEXR_IEX_LIBRARY} ${OPENEXR_HALF_LIBRARY} ${OPENEXR_ILMTHREAD_LIBRARY} ${ZLIB_LIBRARY})
|
||||||
OPENEXR_INCLUDE_DIR
|
|
||||||
OPENEXR_LIBRARIES
|
IF (OPENEXR_INCLUDE_PATH AND OPENEXR_IMATH_LIBRARY AND OPENEXR_ILMIMF_LIBRARY AND OPENEXR_IEX_LIBRARY AND OPENEXR_HALF_LIBRARY)
|
||||||
OPENEXR_ILMIMF_LIBRARY
|
SET(OPENEXR_FOUND TRUE)
|
||||||
OPENEXR_IMATH_LIBRARY
|
SET(OPENEXR_INCLUDE_PATHS ${OPENEXR_INCLUDE_PATH} CACHE STRING "The include paths needed to use OpenEXR")
|
||||||
OPENEXR_IEX_LIBRARY
|
SET(OPENEXR_LIBRARIES ${OPENEXR_IMATH_LIBRARY} ${OPENEXR_ILMIMF_LIBRARY} ${OPENEXR_IEX_LIBRARY} ${OPENEXR_HALF_LIBRARY} ${ZLIB_LIBRARY} CACHE STRING "The libraries needed to use OpenEXR")
|
||||||
OPENEXR_HALF_LIBRARY)
|
|
||||||
|
IF(OPENEXR_ILMTHREAD_LIBRARY)
|
||||||
|
SET(OPENEXR_LIBRARIES ${OPENEXR_LIBRARIES} ${OPENEXR_ILMTHREAD_LIBRARY})
|
||||||
|
ENDIF(OPENEXR_ILMTHREAD_LIBRARY)
|
||||||
|
ENDIF (OPENEXR_INCLUDE_PATH AND OPENEXR_IMATH_LIBRARY AND OPENEXR_ILMIMF_LIBRARY AND OPENEXR_IEX_LIBRARY AND OPENEXR_HALF_LIBRARY)
|
||||||
|
|
||||||
|
IF(OPENEXR_FOUND)
|
||||||
|
IF(NOT OPENEXR_FIND_QUIETLY)
|
||||||
|
MESSAGE(STATUS "Found OpenEXR: ${OPENEXR_ILMIMF_LIBRARY}")
|
||||||
|
ENDIF(NOT OPENEXR_FIND_QUIETLY)
|
||||||
|
ELSE(OPENEXR_FOUND)
|
||||||
|
IF(OPENEXR_FIND_REQUIRED)
|
||||||
|
MESSAGE(FATAL_ERROR "Could not find OpenEXR library")
|
||||||
|
ENDIF(OPENEXR_FIND_REQUIRED)
|
||||||
|
ENDIF(OPENEXR_FOUND)
|
||||||
|
|
||||||
|
MARK_AS_ADVANCED(
|
||||||
|
OPENEXR_INCLUDE_PATHS
|
||||||
|
OPENEXR_LIBRARIES
|
||||||
|
OPENEXR_ILMIMF_LIBRARY
|
||||||
|
OPENEXR_IMATH_LIBRARY
|
||||||
|
OPENEXR_IEX_LIBRARY
|
||||||
|
OPENEXR_HALF_LIBRARY)
|
||||||
|
Loading…
Reference in New Issue
Block a user