blob: 32457bcd60cdcd815cae1000270e50d36dc63f49 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
|
# -*- cmake -*-
# - Find uriparser
# Find the URIPARSER includes and library
# This module defines
# URIPARSER_INCLUDE_DIRS, where to find uriparser.h, etc.
# URIPARSER_LIBRARIES, the libraries needed to use uriparser.
# URIPARSER_FOUND, If false, do not try to use uriparser.
#
# This FindURIPARSER is about 43 times as fast the one provided with cmake (2.8.x),
# because it doesn't look up the version of uriparser, resulting in a dramatic
# speed up for configure (from 4 minutes 22 seconds to 6 seconds).
#
# Note: Since this file is only used for standalone, the windows
# specific parts were left out.
FIND_PATH(URIPARSER_INCLUDE_DIR uriparser/uri.h
NO_SYSTEM_ENVIRONMENT_PATH
)
FIND_LIBRARY(URIPARSER_LIBRARY z)
if (URIPARSER_LIBRARY AND URIPARSER_INCLUDE_DIR)
SET(URIPARSER_INCLUDE_DIRS ${URIPARSER_INCLUDE_DIR})
SET(URIPARSER_LIBRARIES ${URIPARSER_LIBRARY})
SET(URIPARSER_FOUND "YES")
else (URIPARSER_LIBRARY AND URIPARSER_INCLUDE_DIR)
SET(URIPARSER_FOUND "NO")
endif (URIPARSER_LIBRARY AND URIPARSER_INCLUDE_DIR)
if (URIPARSER_FOUND)
if (NOT URIPARSER_FIND_QUIETLY)
message(STATUS "Found URIPARSER: ${URIPARSER_LIBRARIES}")
SET(URIPARSER_FIND_QUIETLY TRUE)
endif (NOT URIPARSER_FIND_QUIETLY)
else (URIPARSER_FOUND)
if (URIPARSER_FIND_REQUIRED)
message(FATAL_ERROR "Could not find URIPARSER library")
endif (URIPARSER_FIND_REQUIRED)
endif (URIPARSER_FOUND)
mark_as_advanced(
URIPARSER_LIBRARY
URIPARSER_INCLUDE_DIR
)
|