#------------------------------------------------------------------- # 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 LIBZIP # Once done, this will define # # LIBZIP_FOUND - system has LIBZIP # LIBZIP_INCLUDE_DIRS - the LIBZIP include directories # LIBZIP_LIBRARIES - link these to use LIBZIP include(FindPkgMacros) findpkg_begin(LIBZIP) # Get path, convert backslashes as ${ENV_${var}} getenv_path(LIBZIP_HOME) # construct search paths # set(LIBZIP_PREFIX_PATH ${LIBZIP_HOME} ${ENV_LIBZIP_HOME} ) create_search_paths(LIBZIP) # redo search if prefix path changed clear_if_changed(LIBZIP_PREFIX_PATH LIBZIP_LIBRARY_FWK LIBZIP_LIBRARY_REL LIBZIP_LIBRARY_DBG LIBZIP_INCLUDE_DIR ) set(LIBZIP_LIBRARY_NAMES zip) get_debug_names(LIBZIP_LIBRARY_NAMES) use_pkgconfig(LIBZIP_PKGC zzip-LIBZIP-config) findpkg_framework(LIBZIP) find_path(LIBZIP_INCLUDE_DIR NAMES zip.h HINTS ${LIBZIP_INC_SEARCH_PATH} ${LIBZIP_PKGC_INCLUDE_DIRS}) find_library(LIBZIP_LIBRARY_REL NAMES ${LIBZIP_LIBRARY_NAMES} HINTS ${LIBZIP_LIB_SEARCH_PATH} ${LIBZIP_PKGC_LIBRARY_DIRS} PATH_SUFFIXES "" Release RelWithDebInfo MinSizeRel ${ANDROID_ABI}) find_library(LIBZIP_LIBRARY_DBG NAMES ${LIBZIP_LIBRARY_NAMES_DBG} HINTS ${LIBZIP_LIB_SEARCH_PATH} ${LIBZIP_PKGC_LIBRARY_DIRS} PATH_SUFFIXES "" Debug ${ANDROID_ABI}) make_library_set(LIBZIP_LIBRARY) findpkg_finish(LIBZIP)