2 # Find the native JPEG includes and library
4 # JPEG_INCLUDE_DIR, where to find jpeglib.h, etc.
5 # JPEG_LIBRARIES, the libraries needed to use JPEG.
6 # JPEG_FOUND, If false, do not try to use JPEG.
7 # also defined, but not for general use are
8 # JPEG_LIBRARY, where to find the JPEG library.
10 FIND_PATH(JPEG_INCLUDE_DIR jpeglib.h)
12 SET(JPEG_NAMES ${JPEG_NAMES} jpeg)
13 FIND_LIBRARY(JPEG_LIBRARY NAMES ${JPEG_NAMES} )
15 # handle the QUIETLY and REQUIRED arguments and set JPEG_FOUND to TRUE if
16 # all listed variables are TRUE
17 INCLUDE(FindPackageHandleStandardArgs)
18 FIND_PACKAGE_HANDLE_STANDARD_ARGS(JPEG DEFAULT_MSG JPEG_LIBRARY JPEG_INCLUDE_DIR)
21 SET(JPEG_LIBRARIES ${JPEG_LIBRARY})
24 # Deprecated declarations.
25 SET (NATIVE_JPEG_INCLUDE_PATH ${JPEG_INCLUDE_DIR} )
27 GET_FILENAME_COMPONENT (NATIVE_JPEG_LIB_PATH ${JPEG_LIBRARY} PATH)
30 MARK_AS_ADVANCED(JPEG_LIBRARY JPEG_INCLUDE_DIR )