#------------------------------------------------------------------- # This file is part of the CMake build system for OGRE # (Object-oriented Graphics Rendering Engine) # For the latest info, see http://www.ogre3d.org/ # # The contents of this file are placed in the public domain. Feel # free to make use of it in any way you like. #------------------------------------------------------------------- # - Try to find OPENVR # Once done, this will define # # OPENVR_FOUND - system has OPENVR # OPENVR_INCLUDE_DIRS - the OPENVR include directories # OPENVR_LIBRARIES - link these to use OPENVR include(FindPkgMacros) findpkg_begin(OPENVR) # Get path, convert backslashes as ${ENV_${var}} getenv_path(OPENVR_HOME) # construct search paths set(OPENVR_PREFIX_PATH ${OPENVR_HOME} ${ENV_OPENVR_HOME} ) create_search_paths(openvr) # redo search if prefix path changed clear_if_changed(OPENVR_PREFIX_PATH OPENVR_LIBRARY_FWK OPENVR_LIBRARY_REL OPENVR_LIBRARY_DBG OPENVR_INCLUDE_DIR ) set(OPENVR_LIBRARY_NAMES OPENVR openvr_api openvr_api64) get_debug_names(OPENVR_LIBRARY_NAMES) findpkg_framework(openvr) find_path(OPENVR_INCLUDE_DIR NAMES openvr/openvr.h HINTS ${OPENVR_INC_SEARCH_PATH} ${OPENVR_PKGC_INCLUDE_DIRS}) find_library(OPENVR_LIBRARY_REL NAMES ${OPENVR_LIBRARY_NAMES} HINTS ${OPENVR_LIB_SEARCH_PATH} ${OPENVR_PKGC_LIBRARY_DIRS} PATH_SUFFIXES "" Release RelWithDebInfo MinSizeRel ${ANDROID_ABI}) find_library(OPENVR_LIBRARY_DBG NAMES ${OPENVR_LIBRARY_NAMES_DBG} HINTS ${OPENVR_LIB_SEARCH_PATH} ${OPENVR_PKGC_LIBRARY_DIRS} PATH_SUFFIXES "" Debug ${ANDROID_ABI}) make_library_set(OPENVR_LIBRARY) findpkg_finish(OPENVR)