mirror of
https://github.com/microsoft/vcpkg.git
synced 2025-01-04 08:05:34 +08:00
cc093a8224
* [harfbuzz] Use meson * [harfbuzz] Add config file for CMake * [harfbuzz,pango] Remove glib option for harfbuzz * [libass,libmupdf,qt5-base,skia] Fix for harfbuzz * Back out meson edit already applied in https://github.com/microsoft/vcpkg/pull/15258 * [harfbuzz] Fixup pkgconfig * [libass] Bump port version * Revert "[libass,libmupdf,qt5-base,skia] Fix for harfbuzz" This reverts commit 3ba27c6c1c10a2889a8c5e028d010916f91418e3. * [harfbuzz] Update to 2.7.4 * update baseline record * Restore glib feature for harfbuzz and remove vagrant change * Update port version * Change over to manifests * Update port version Co-authored-by: Ebrahim Byagowi <ebrahim@gnu.org> Co-authored-by: Billy Robert O'Neal III <bion@microsoft.com> Co-authored-by: JackBoosY <yuzaiyang@beyondsoft.com>
59 lines
2.5 KiB
CMake
59 lines
2.5 KiB
CMake
if(TARGET harfbuzz)
|
|
return()
|
|
endif()
|
|
|
|
add_library(harfbuzz INTERFACE IMPORTED GLOBAL)
|
|
add_library(harfbuzz::harfbuzz ALIAS harfbuzz)
|
|
|
|
find_library(HARFBUZZ_LIBRARY_DEBUG NAMES harfbuzz PATHS "${_VCPKG_INSTALLED_DIR}/${VCPKG_TARGET_TRIPLET}/debug" PATH_SUFFIXES lib NO_DEFAULT_PATH)
|
|
if(HARFBUZZ_LIBRARY_DEBUG)
|
|
target_link_libraries(harfbuzz INTERFACE $<$<CONFIG:DEBUG>:${HARFBUZZ_LIBRARY_DEBUG}>)
|
|
endif()
|
|
|
|
find_library(HARFBUZZ_LIBRARY_RELEASE NAMES harfbuzz PATHS "${_VCPKG_INSTALLED_DIR}/${VCPKG_TARGET_TRIPLET}" PATH_SUFFIXES lib NO_DEFAULT_PATH)
|
|
if(HARFBUZZ_LIBRARY_RELEASE)
|
|
target_link_libraries(harfbuzz INTERFACE $<$<NOT:$<CONFIG:DEBUG>>:${HARFBUZZ_LIBRARY_RELEASE}>)
|
|
endif()
|
|
|
|
set(HARFBUZZ_FEATURES @FEATURES@)
|
|
|
|
if(APPLE)
|
|
find_library(APPLICATIONSERVICES_LIBRARY ApplicationServices)
|
|
target_link_libraries(harfbuzz INTERFACE ${APPLICATIONSERVICES_LIBRARY})
|
|
endif()
|
|
|
|
find_package(freetype CONFIG REQUIRED)
|
|
target_link_libraries(harfbuzz INTERFACE freetype)
|
|
|
|
if ("graphite2" IN_LIST HARFBUZZ_FEATURES)
|
|
find_library(GRAPHITE2_LIBRARY_DEBUG NAMES graphite2 PATHS "${_VCPKG_INSTALLED_DIR}/${VCPKG_TARGET_TRIPLET}/debug" PATH_SUFFIXES lib NO_DEFAULT_PATH)
|
|
if(GRAPHITE2_LIBRARY_DEBUG)
|
|
target_link_libraries(harfbuzz INTERFACE $<$<CONFIG:DEBUG>:${GRAPHITE2_LIBRARY_DEBUG}>)
|
|
endif()
|
|
|
|
find_library(GRAPHITE2_LIBRARY_RELEASE NAMES graphite2 PATHS "${_VCPKG_INSTALLED_DIR}/${VCPKG_TARGET_TRIPLET}" PATH_SUFFIXES lib NO_DEFAULT_PATH)
|
|
if(GRAPHITE2_LIBRARY_RELEASE)
|
|
target_link_libraries(harfbuzz INTERFACE $<$<NOT:$<CONFIG:DEBUG>>:${GRAPHITE2_LIBRARY_RELEASE}>)
|
|
endif()
|
|
endif()
|
|
|
|
if ("glib" IN_LIST HARFBUZZ_FEATURES)
|
|
find_library(GLIB_LIBRARY_DEBUG NAMES glib glib-2.0 PATHS "${_VCPKG_INSTALLED_DIR}/${VCPKG_TARGET_TRIPLET}/debug" PATH_SUFFIXES lib NO_DEFAULT_PATH)
|
|
if(GLIB_LIBRARY_DEBUG)
|
|
target_link_libraries(harfbuzz INTERFACE $<$<CONFIG:DEBUG>:${GLIB_LIBRARY_DEBUG}>)
|
|
endif()
|
|
|
|
find_library(GLIB_LIBRARY_RELEASE NAMES glib glib-2.0 PATHS "${_VCPKG_INSTALLED_DIR}/${VCPKG_TARGET_TRIPLET}" PATH_SUFFIXES lib NO_DEFAULT_PATH)
|
|
if(GLIB_LIBRARY_RELEASE)
|
|
target_link_libraries(harfbuzz INTERFACE $<$<NOT:$<CONFIG:DEBUG>>:${GLIB_LIBRARY_RELEASE}>)
|
|
endif()
|
|
endif()
|
|
|
|
if ("icu" IN_LIST HARFBUZZ_FEATURES)
|
|
find_package(ICU 61 COMPONENTS uc REQUIRED)
|
|
target_link_libraries(harfbuzz INTERFACE ICU::uc)
|
|
endif()
|
|
|
|
get_filename_component(_INSTALL_DIR "${CMAKE_CURRENT_LIST_DIR}/../../" ABSOLUTE)
|
|
target_include_directories(harfbuzz INTERFACE ${_INSTALL_DIR}/include/harfbuzz)
|