1
# https://code.google.com/p/osgearth-for-android/source/browse/trunk/CMakeModules/FindLibZip.cmake?r=4
3
# osgEarth - Dynamic map generation toolkit for OpenSceneGraph
4
# Copyright 2008-2010 Pelican Mapping
7
# git://github.com/gwaldron/osgearth
9
# osgEarth is free software; you can redistribute it and/or modify
10
# it under the terms of the GNU Lesser General Public License as published by
11
# the Free Software Foundation; either version 2 of the License, or
12
# (at your option) any later version.
14
# This program is distributed in the hope that it will be useful,
15
# but WITHOUT ANY WARRANTY; without even the implied warranty of
16
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
17
# GNU Lesser General Public License for more details.
19
# You should have received a copy of the GNU Lesser General Public License
20
# along with this program. If not, see <http://www.gnu.org/licenses/>
26
# LIBZIP_FOUND, if false, do not try to link to libzip
27
# LIBZIP_INCLUDE_DIR, where to find the headers
30
FIND_PATH(LIBZIP_INCLUDE_DIR zip.h
31
$ENV{LIBZIP_DIR}/include
35
$ENV{OSG_ROOT}/include
41
/opt/local/include # DarwinPorts
42
/opt/csw/include # Blastwave
44
[HKEY_LOCAL_MACHINE\\SYSTEM\\CurrentControlSet\\Control\\Session\ Manager\\Environment;OSG_ROOT]/include
48
FIND_LIBRARY(LIBZIP_LIBRARY
64
[HKEY_LOCAL_MACHINE\\SYSTEM\\CurrentControlSet\\Control\\Session\ Manager\\Environment;OSG_ROOT]/lib
68
SET(LIBZIP_FOUND "NO")
69
IF(LIBZIP_LIBRARY AND LIBZIP_INCLUDE_DIR)
70
SET(LIBZIP_FOUND "YES")
71
ENDIF(LIBZIP_LIBRARY AND LIBZIP_INCLUDE_DIR)
73
INCLUDE(FindPackageHandleStandardArgs)
74
FIND_PACKAGE_HANDLE_STANDARD_ARGS(LIBZIP DEFAULT_MSG LIBZIP_LIBRARY LIBZIP_INCLUDE_DIR)