File: FindMiniz.cmake

package info (click to toggle)
libwebsockets 4.3.5-3
  • links: PTS
  • area: main
  • in suites: forky, sid
  • size: 31,404 kB
  • sloc: ansic: 194,409; javascript: 1,550; sh: 1,387; cpp: 505; java: 461; perl: 405; xml: 118; makefile: 76; awk: 5
file content (35 lines) | stat: -rw-r--r-- 867 bytes parent folder | download | duplicates (4)
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
# This module tries to find miniz library and include files
#
# MINIZ_INCLUDE_DIR, path where to find miniz.h
# MINIZ_LIBRARY_DIR, path where to find libminiz.so
# MINIZ_LIBRARIES, the library to link against
# MINIZ_FOUND, If false, do not try to use miniz
#
# This currently works probably only for Linux

FIND_PATH ( MINIZ_INCLUDE_DIR miniz.h
    /usr/local/include
    /usr/include
)

FIND_LIBRARY ( MINIZ_LIBRARIES libminiz.so libminiz.a libminiz.so.2 libminiz.so.0.1
    /usr/local/lib
    /usr/local/lib64
    /usr/lib
    /usr/lib64
)

GET_FILENAME_COMPONENT( MINIZ_LIBRARY_DIR ${MINIZ_LIBRARIES} PATH )

SET ( MINIZ_FOUND "NO" )
IF ( MINIZ_INCLUDE_DIR )
    IF ( MINIZ_LIBRARIES )
        SET ( MINIZ_FOUND "YES" )
    ENDIF ( MINIZ_LIBRARIES )
ENDIF ( MINIZ_INCLUDE_DIR )

MARK_AS_ADVANCED(
    MINIZ_LIBRARY_DIR
    MINIZ_INCLUDE_DIR
    MINIZ_LIBRARIES
)