diff --git a/src/harfbuzz-config.cmake.in b/src/harfbuzz-config.cmake.in index 304410d9bae..43c10a0e2f5 100644 --- a/src/harfbuzz-config.cmake.in +++ b/src/harfbuzz-config.cmake.in @@ -24,6 +24,7 @@ unset(_harfbuzz_libdir_iter) # Get the include subdir. set(_harfbuzz_includedir "@includedir@") string(REPLACE "${_harfbuzz_remove_string}/" "" _harfbuzz_includedir "${_harfbuzz_includedir}") +cmake_path(APPEND "${_harfbuzz_prefix}" "${_harfbuzz_includedir}" OUTPUT_VARIABLE _harfbuzz_includedir) # Extract version information from libtool. set(_harfbuzz_version_info "@HB_LIBTOOL_VERSION_INFO@") @@ -48,18 +49,18 @@ endif () # Add the libraries. add_library(harfbuzz::harfbuzz SHARED IMPORTED) set_target_properties(harfbuzz::harfbuzz PROPERTIES - INTERFACE_INCLUDE_DIRECTORIES "${_harfbuzz_prefix}/${_harfbuzz_includedir}/harfbuzz" + INTERFACE_INCLUDE_DIRECTORIES "${_harfbuzz_includedir}/harfbuzz" IMPORTED_LOCATION "${_harfbuzz_prefix}/${_harfbuzz_libdir}/libharfbuzz${_harfbuzz_lib_suffix}") add_library(harfbuzz::icu SHARED IMPORTED) set_target_properties(harfbuzz::icu PROPERTIES - INTERFACE_INCLUDE_DIRECTORIES "${_harfbuzz_prefix}/${_harfbuzz_includedir}/harfbuzz" + INTERFACE_INCLUDE_DIRECTORIES "${_harfbuzz_includedir}/harfbuzz" INTERFACE_LINK_LIBRARIES "harfbuzz::harfbuzz" IMPORTED_LOCATION "${_harfbuzz_prefix}/${_harfbuzz_libdir}/libharfbuzz-icu${_harfbuzz_lib_suffix}") add_library(harfbuzz::subset SHARED IMPORTED) set_target_properties(harfbuzz::subset PROPERTIES - INTERFACE_INCLUDE_DIRECTORIES "${_harfbuzz_prefix}/${_harfbuzz_includedir}/harfbuzz" + INTERFACE_INCLUDE_DIRECTORIES "${_harfbuzz_includedir}/harfbuzz" INTERFACE_LINK_LIBRARIES "harfbuzz::harfbuzz" IMPORTED_LOCATION "${_harfbuzz_prefix}/${_harfbuzz_libdir}/libharfbuzz-subset${_harfbuzz_lib_suffix}") @@ -68,7 +69,7 @@ set(_harfbuzz_have_gobject "@have_gobject@") if (_harfbuzz_have_gobject) add_library(harfbuzz::gobject SHARED IMPORTED) set_target_properties(harfbuzz::gobject PROPERTIES - INTERFACE_INCLUDE_DIRECTORIES "${_harfbuzz_prefix}/${_harfbuzz_includedir}/harfbuzz" + INTERFACE_INCLUDE_DIRECTORIES "${_harfbuzz_includedir}/harfbuzz" INTERFACE_LINK_LIBRARIES "harfbuzz::harfbuzz" IMPORTED_LOCATION "${_harfbuzz_prefix}/${_harfbuzz_libdir}/libharfbuzz-gobject${_harfbuzz_lib_suffix}") endif ()