_find_package(${ARGS})

if(TARGET OpenEXR::IlmImf AND NOT OPENEXR_LIBRARIES AND NOT OPENEXR_FOUND)
  set(OPENEXR_FOUND TRUE CACHE BOOL "")
  set(OpenEXR_FOUND TRUE CACHE BOOL "")
  set(OPENEXR_VERSION "2.5.0" CACHE STRING "")
  set(OpenEXR_VERSION "2.5.0" CACHE STRING "")
  get_target_property(OpenEXR_INCLUDE_DIRS OpenEXR::IlmImf INTERFACE_INCLUDE_DIRECTORIES)
  get_target_property(OPENEXR_INCLUDE_PATHS OpenEXR::IlmImf INTERFACE_INCLUDE_DIRECTORIES)
  get_target_property(OPENEXR_INCLUDE_DIRS OpenEXR::IlmImf INTERFACE_INCLUDE_DIRECTORIES)
  get_target_property(OPENEXR_INCLUDE_DIR OpenEXR::IlmImf INTERFACE_INCLUDE_DIRECTORIES)
  set(OpenEXR_INCLUDE_DIRS ${OpenEXR_INCLUDE_DIRS} CACHE STRING "")
  set(OPENEXR_INCLUDE_PATHS ${OPENEXR_INCLUDE_PATHS} CACHE STRING "")
  set(OPENEXR_INCLUDE_DIRS ${OPENEXR_INCLUDE_DIRS} CACHE STRING "")
  set(OPENEXR_INCLUDE_DIR ${OPENEXR_INCLUDE_DIR} CACHE STRING "")
  set(OPENEXR_ILMIMF_LIBRARY "OpenEXR::IlmImf" CACHE STRING "")
  set(OPENEXR_ILMIMFUTIL_LIBRARY "OpenEXR::IlmImfUtil" CACHE STRING "")
  set(OPENEXR_LIBRARIES ${OPENEXR_ILMIMFUTIL_LIBRARY} ${OPENEXR_ILMIMF_LIBRARY} CACHE STRING "")
endif()

if(TARGET IlmBase::Half AND NOT ILMBASE_LIBRARIES AND NOT ILMBASE_FOUND)
  set(ILMBASE_FOUND TRUE CACHE BOOL "")
  set(IlmBASE_FOUND TRUE CACHE BOOL "")
  set(ILMBASE_VERSION "2.5.0" CACHE STRING "")
  set(IlmBASE_VERSION "2.5.0" CACHE STRING "")
  get_target_property(ILMBASE_INCLUDE_DIR IlmBase::Half INTERFACE_INCLUDE_DIRECTORIES)
  get_target_property(ILMBASE_INCLUDE_DIRS IlmBase::Half INTERFACE_INCLUDE_DIRECTORIES)
  get_target_property(ILMBASE_INCLUDE_PATHS IlmBase::Half INTERFACE_INCLUDE_DIRECTORIES)
  set(ILMBASE_INCLUDE_DIR ${ILMBASE_INCLUDE_DIR} CACHE STRING "")
  set(ILMBASE_INCLUDE_DIRS ${ILMBASE_INCLUDE_DIRS} CACHE STRING "")
  set(ILMBASE_INCLUDE_PATHS ${ILMBASE_INCLUDE_PATHS} CACHE STRING "")
  set(OPENEXR_HALF_LIBRARY "IlmBase::Half" CACHE STRING "")
  set(OPENEXR_IEX_LIBRARY "IlmBase::Iex" CACHE STRING "")
  set(OPENEXR_IEXMATH_LIBRARY "IlmBase::IexMath" CACHE STRING "")
  set(OPENEXR_ILMTHREAD_LIBRARY "IlmBase::IlmThread" CACHE STRING "")
  set(OPENEXR_IMATH_LIBRARY "IlmBase::Imath" CACHE STRING "")
  set(ILMBASE_LIBRARIES ${OPENEXR_IMATH_LIBRARY} ${OPENEXR_ILMTHREAD_LIBRARY} ${OPENEXR_IEXMATH_LIBRARY} ${OPENEXR_IEX_LIBRARY} ${OPENEXR_HALF_LIBRARY} CACHE STRING "")
endif()
