diff options
| author | Robert Schumacher <roschuma@microsoft.com> | 2016-10-10 23:07:25 -0700 |
|---|---|---|
| committer | Robert Schumacher <roschuma@microsoft.com> | 2016-10-10 23:07:25 -0700 |
| commit | c494892eb24ce6f84c777f24dfceb71a4988fd24 (patch) | |
| tree | 71cfa3111df8c238e6fec721783ed37cebc419c3 | |
| parent | a0f621c0fca2c3de8bd5249f023979b800c543cf (diff) | |
| download | vcpkg-c494892eb24ce6f84c777f24dfceb71a4988fd24.tar.gz vcpkg-c494892eb24ce6f84c777f24dfceb71a4988fd24.zip | |
[freetype] Adjust include paths. Fix cmake config deployment.
| -rw-r--r-- | ports/freetype/0002-Add-CONFIG_INSTALL_PATH-option.patch | 29 | ||||
| -rw-r--r-- | ports/freetype/CONTROL | 2 | ||||
| -rw-r--r-- | ports/freetype/portfile.cmake | 21 |
3 files changed, 42 insertions, 10 deletions
diff --git a/ports/freetype/0002-Add-CONFIG_INSTALL_PATH-option.patch b/ports/freetype/0002-Add-CONFIG_INSTALL_PATH-option.patch new file mode 100644 index 000000000..33b0b920f --- /dev/null +++ b/ports/freetype/0002-Add-CONFIG_INSTALL_PATH-option.patch @@ -0,0 +1,29 @@ +From 59ebd2985f081229edc3c487367a1e5d5ac8db9a Mon Sep 17 00:00:00 2001 +From: Robert Schumacher <roschuma@microsoft.com> +Date: Mon, 10 Oct 2016 23:00:38 -0700 +Subject: [PATCH] Add CONFIG_INSTALL_PATH option + +--- + CMakeLists.txt | 5 ++++- + 1 file changed, 4 insertions(+), 1 deletion(-) + +diff --git a/CMakeLists.txt b/CMakeLists.txt +index 774737d..5de689c 100644 +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -401,8 +401,11 @@ install(TARGETS freetype + ARCHIVE DESTINATION lib + FRAMEWORK DESTINATION Library/Frameworks + ) ++ ++set(CONFIG_INSTALL_PATH "lib/cmake/freetype" CACHE STRING "location to install cmake config files") ++ + install(EXPORT freetype-targets +- DESTINATION lib/cmake/freetype ++ DESTINATION ${CONFIG_INSTALL_PATH} + FILE freetype-config.cmake + ) + +-- +2.9.2.windows.1 + diff --git a/ports/freetype/CONTROL b/ports/freetype/CONTROL index 87454460e..39def18fc 100644 --- a/ports/freetype/CONTROL +++ b/ports/freetype/CONTROL @@ -1,3 +1,3 @@ Source: freetype -Version: 2.6.3 +Version: 2.6.3-1 Description: A library to render fonts.
\ No newline at end of file diff --git a/ports/freetype/portfile.cmake b/ports/freetype/portfile.cmake index 390030551..f0d5728f6 100644 --- a/ports/freetype/portfile.cmake +++ b/ports/freetype/portfile.cmake @@ -10,26 +10,29 @@ vcpkg_extract_source_archive(${ARCHIVE}) vcpkg_apply_patches( SOURCE_PATH ${SOURCE_PATH} PATCHES ${CMAKE_CURRENT_LIST_DIR}/0001-Support-Windows-DLLs-via-CMAKE_WINDOWS_EXPORT_ALL_SY.patch + ${CMAKE_CURRENT_LIST_DIR}/0002-Add-CONFIG_INSTALL_PATH-option.patch ) vcpkg_configure_cmake( SOURCE_PATH ${SOURCE_PATH} OPTIONS -DBUILD_SHARED_LIBS=ON + -DCONFIG_INSTALL_PATH=share/freetype ) vcpkg_install_cmake() -file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/include) -file(MAKE_DIRECTORY ${CURRENT_PACKAGES_DIR}/include ${CURRENT_PACKAGES_DIR}/share) -file(RENAME ${CURRENT_PACKAGES_DIR}/debug/include/freetype2/freetype ${CURRENT_PACKAGES_DIR}/include/freetype2) -file(RENAME ${CURRENT_PACKAGES_DIR}/debug/include/freetype2/ft2build.h ${CURRENT_PACKAGES_DIR}/include/freetype2/ft2build.h) -file(RENAME ${CURRENT_PACKAGES_DIR}/lib/cmake/freetype ${CURRENT_PACKAGES_DIR}/share/freetype) -file(RENAME ${CURRENT_PACKAGES_DIR}/debug/lib/cmake/freetype/freetype-config-debug.cmake ${CURRENT_PACKAGES_DIR}/share/freetype/freetype-config-debug.cmake) - -file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/lib/cmake) -file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/debug/lib/cmake) +file(RENAME ${CURRENT_PACKAGES_DIR}/include/freetype2/freetype ${CURRENT_PACKAGES_DIR}/include/freetype) +file(RENAME ${CURRENT_PACKAGES_DIR}/include/freetype2/ft2build.h ${CURRENT_PACKAGES_DIR}/include/ft2build.h) +file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/include/freetype2) file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/debug/include) + +file(READ ${CURRENT_PACKAGES_DIR}/debug/share/freetype/freetype-config-debug.cmake DEBUG_MODULE) +string(REPLACE "\${_IMPORT_PREFIX}" "\${_IMPORT_PREFIX}/debug" DEBUG_MODULE "${DEBUG_MODULE}") +file(WRITE ${CURRENT_PACKAGES_DIR}/share/freetype/freetype-config-debug.cmake "${DEBUG_MODULE}") + +file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/debug/share) + file(COPY ${SOURCE_PATH}/docs/LICENSE.TXT ${SOURCE_PATH}/docs/FTL.TXT |
