FindFreetype¶
Finds the FreeType font renderer library:
find_package(Freetype [<version>] [...])
Добавлено в версии 3.7: Debug and Release (optimized) library variants are found separately.
Imported Targets¶
This module provides the following Imported Targets:
Freetype::Freetype
Добавлено в версии 3.10.
Target encapsulating the Freetype library usage requirements, available if Freetype is found.
Result Variables¶
This module defines the following variables:
Freetype_FOUND
Добавлено в версии 3.3.
Boolean indicating whether (the requested version of) Freetype was found.
Freetype_VERSION
Добавлено в версии 4.2.
The version of Freetype found.
FREETYPE_INCLUDE_DIRS
Include directories containing headers needed to use Freetype. This is the concatenation of
FREETYPE_INCLUDE_DIR_ft2build
andFREETYPE_INCLUDE_DIR_freetype2
variables.FREETYPE_LIBRARIES
Libraries needed to link against for using Freetype.
Добавлено в версии 3.7: Debug and Release library variants are found separately.
Cache Variables¶
The following cache variables may also be set:
FREETYPE_INCLUDE_DIR_ft2build
The directory containing the main Freetype API configuration header.
FREETYPE_INCLUDE_DIR_freetype2
The directory containing Freetype public headers.
Hints¶
This module accepts the following variables:
FREETYPE_DIR
The user may set this environment variable to the root directory of a Freetype installation to find Freetype in non-standard locations.
Deprecated Variables¶
The following variables are provided for backward compatibility:
FREETYPE_FOUND
Устарело, начиная с версии 4.2: Use
Freetype_FOUND
, which has the same value.Boolean indicating whether (the requested version of) Freetype was found.
FREETYPE_VERSION_STRING
Устарело, начиная с версии 4.2: Superseded by the
Freetype_VERSION
.The version of Freetype found.
Examples¶
Finding Freetype and linking it to a project target:
find_package(Freetype)
target_link_libraries(project_target PRIVATE Freetype::Freetype)