Warning, /graphics/okular/cmake/modules/FindLibZip.cmake is written in an unsupported language. File is not indexed.
0001 # - Try to find libzip
0002 # Once done this will define
0003 #
0004 # LIBZIP_FOUND - system has the zip library
0005 # LIBZIP_INCLUDE_DIR - the zip include directory
0006 # LIBZIP_LIBRARY - Link this to use the zip library
0007 #
0008 # SPDX-FileCopyrightText: 2006 Pino Toscano <toscano.pino@tiscali.it>
0009 # SPDX-License-Identifier: BSD-3-Clause
0010
0011 if (LIBZIP_LIBRARY AND LIBZIP_INCLUDE_DIR)
0012 # in cache already
0013 set(LIBZIP_FOUND TRUE)
0014 else (LIBZIP_LIBRARY AND LIBZIP_INCLUDE_DIR)
0015
0016 find_path(LIBZIP_INCLUDE_DIR zip.h
0017 ${GNUWIN32_DIR}/include
0018 )
0019
0020 find_library(LIBZIP_LIBRARY NAMES zip
0021 PATHS
0022 ${GNUWIN32_DIR}/lib
0023 )
0024
0025 include(FindPackageHandleStandardArgs)
0026 FIND_PACKAGE_HANDLE_STANDARD_ARGS(LibZip DEFAULT_MSG LIBZIP_LIBRARY LIBZIP_INCLUDE_DIR)
0027
0028 # ensure that they are cached
0029 set(LIBZIP_INCLUDE_DIR ${LIBZIP_INCLUDE_DIR} CACHE INTERNAL "The libzip include path")
0030 set(LIBZIP_LIBRARY ${LIBZIP_LIBRARY} CACHE INTERNAL "The libraries needed to use libzip")
0031
0032 endif (LIBZIP_LIBRARY AND LIBZIP_INCLUDE_DIR)