diff options
author | Boris Dalstein <dalboris@gmail.com> | 2020-08-25 13:53:54 +0200 |
---|---|---|
committer | Nikolaus Waxweiler <madigens@gmail.com> | 2020-09-03 10:57:50 +0100 |
commit | 69353a19a197b0ab89b8382966c07f072fed8453 (patch) | |
tree | 978ab421cd3917e3810076d2b84e39f7b83a9483 /CMakeLists.txt | |
parent | 600d59e343a0d6529a2cd714bf90b70a107b39d7 (diff) | |
download | freetype2-69353a19a197b0ab89b8382966c07f072fed8453.tar.gz |
Export version info (#58935)
Diffstat (limited to 'CMakeLists.txt')
-rw-r--r-- | CMakeLists.txt | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt index c9befb421..c2fb86184 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -527,6 +527,12 @@ if (NOT SKIP_INSTALL_LIBRARIES AND NOT SKIP_INSTALL_ALL) COMPONENT pkgconfig) endif () + include(CMakePackageConfigHelpers) + write_basic_package_version_file( + ${PROJECT_BINARY_DIR}/freetype-config-version.cmake + VERSION ${VERSION_MAJOR}.${VERSION_MINOR}.${VERSION_PATCH} + COMPATIBILITY SameMajorVersion) + install( TARGETS freetype EXPORT freetype-targets @@ -540,6 +546,10 @@ if (NOT SKIP_INSTALL_LIBRARIES AND NOT SKIP_INSTALL_ALL) DESTINATION ${CMAKE_INSTALL_LIBDIR}/cmake/freetype FILE freetype-config.cmake COMPONENT headers) + install( + FILES ${PROJECT_BINARY_DIR}/freetype-config-version.cmake + DESTINATION ${CMAKE_INSTALL_LIBDIR}/cmake/freetype + COMPONENT headers) endif () |