PageRenderTime 20ms CodeModel.GetById 12ms app.highlight 3ms RepoModel.GetById 2ms app.codeStats 0ms

/tux-target/CMakeModules/FindFreeType.cmake

http://tux-target.googlecode.com/
CMake | 50 lines | 39 code | 5 blank | 6 comment | 0 complexity | 0c290e87896bc6b568fe994f3b6cf9ea MD5 | raw file
 1# - Locate FreeType library
 2# This module defines
 3#  FREETYPE_LIBRARY, the library to link against
 4#  FREETYPE_FOUND, if false, do not try to link to FREETYPE
 5#  FREETYPE_INCLUDE_DIRS, where to find headers.
 6
 7IF(FREETYPE_LIBRARY AND FREETYPE_INCLUDE_DIRS)
 8  # in cache already
 9  SET(FREETYPE_FIND_QUIETLY TRUE)
10ENDIF(FREETYPE_LIBRARY AND FREETYPE_INCLUDE_DIRS)
11
12
13FIND_PATH(FREETYPE_INCLUDE_DIRS
14  freetype
15  PATHS
16  $ENV{FREETYPE_DIR}/include
17  /usr/local/include
18  /usr/include
19  /sw/include
20  /opt/local/include
21  /opt/csw/include
22  /opt/include
23  PATH_SUFFIXES freetype freetype2
24)
25
26FIND_LIBRARY(FREETYPE_LIBRARY
27  NAMES freetype libfreetype freetype219
28  PATHS
29  $ENV{FREETYPE_DIR}/lib
30  /usr/local/lib
31  /usr/lib
32  /usr/local/X11R6/lib
33  /usr/X11R6/lib
34  /sw/lib
35  /opt/local/lib
36  /opt/csw/lib
37  /opt/lib
38  /usr/freeware/lib64
39)
40
41IF(FREETYPE_LIBRARY AND FREETYPE_INCLUDE_DIRS)
42  SET(FREETYPE_FOUND "YES")
43  IF(NOT FREETYPE_FIND_QUIETLY)
44    MESSAGE(STATUS "Found FreeType: ${FREETYPE_LIBRARY}")
45  ENDIF(NOT FREETYPE_FIND_QUIETLY)
46ELSE(FREETYPE_LIBRARY AND FREETYPE_INCLUDE_DIRS)
47  IF(NOT FREETYPE_FIND_QUIETLY)
48    MESSAGE(STATUS "Warning: Unable to find FreeType!")
49  ENDIF(NOT FREETYPE_FIND_QUIETLY)
50ENDIF(FREETYPE_LIBRARY AND FREETYPE_INCLUDE_DIRS)