#------------------------------------------------------------------- # This file is part of the CMake build system for Scol # # The contents of this file are placed in the public domain. Feel # free to make use of it in any way you like. #------------------------------------------------------------------- # Locate Xavy's SKYX Ogre plugin # This module defines # SKYX_FOUND - True when the SKYX include directory is found. # SKYX_INCLUDE_DIRS - the SKYX include files. # SKYX_LIBRARIES - the SKYX library files. # # SKYX_ROOT is an environment variable that would be set for windows users. # # Created by Jean-François VERDON. This was influenced by the FindBoost.cmake module. # If SKYX_ROOT was defined in the environment, use it. Else, search in default dependency dir. include(FindPkgMacros) findpkg_begin(SKYX) # Get path, convert backslashes as ${ENV_${var}} getenv_path(SKYX_ROOT) # construct search paths set(SKYX_PREFIX_PATH ${ENV_SKYX_HOME} ) create_search_paths(SKYX) # redo search if prefix path changed clear_if_changed(SKYX_PREFIX_PATH SKYX_LIBRARY_FWK SKYX_LIBRARY_REL SKYX_LIBRARY_DBG SKYX_INCLUDE_DIR ) set(SKYX_LIBRARY_NAMES SKYX SkyXStatic) get_debug_names(SKYX_LIBRARY_NAMES) use_pkgconfig(SKYX_PKGC zzip-SKYX-config) findpkg_framework(SKYX) find_path(SKYX_INCLUDE_DIR NAMES SkyX.h HINTS ${SKYX_INC_SEARCH_PATH} ${SKYX_PKGC_INCLUDE_DIRS}) find_library(SKYX_LIBRARY_REL NAMES ${SKYX_LIBRARY_NAMES} HINTS ${SKYX_LIB_SEARCH_PATH} ${SKYX_PKGC_LIBRARY_DIRS} PATH_SUFFIXES "" Release RelWithDebInfo MinSizeRel ${ANDROID_ABI}) find_library(SKYX_LIBRARY_DBG NAMES ${SKYX_LIBRARY_NAMES_DBG} HINTS ${SKYX_LIB_SEARCH_PATH} ${SKYX_PKGC_LIBRARY_DIRS} PATH_SUFFIXES "" Debug ${ANDROID_ABI}) make_library_set(SKYX_LIBRARY) findpkg_finish(SKYX)