summaryrefslogtreecommitdiffstats
path: root/gfx/harfbuzz/src/harfbuzz-config.cmake.in
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-07 17:32:43 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-07 17:32:43 +0000
commit6bf0a5cb5034a7e684dcc3500e841785237ce2dd (patch)
treea68f146d7fa01f0134297619fbe7e33db084e0aa /gfx/harfbuzz/src/harfbuzz-config.cmake.in
parentInitial commit. (diff)
downloadthunderbird-6bf0a5cb5034a7e684dcc3500e841785237ce2dd.tar.xz
thunderbird-6bf0a5cb5034a7e684dcc3500e841785237ce2dd.zip
Adding upstream version 1:115.7.0.upstream/1%115.7.0upstream
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'gfx/harfbuzz/src/harfbuzz-config.cmake.in')
-rw-r--r--gfx/harfbuzz/src/harfbuzz-config.cmake.in62
1 files changed, 62 insertions, 0 deletions
diff --git a/gfx/harfbuzz/src/harfbuzz-config.cmake.in b/gfx/harfbuzz/src/harfbuzz-config.cmake.in
new file mode 100644
index 0000000000..ced97919a2
--- /dev/null
+++ b/gfx/harfbuzz/src/harfbuzz-config.cmake.in
@@ -0,0 +1,62 @@
+set(_harfbuzz_libdir "@libdir@")
+set(_harfbuzz_includedir "@includedir@")
+
+# Extract version information from libtool.
+set(_harfbuzz_version_info "@HB_LIBTOOL_VERSION_INFO@")
+string(REPLACE ":" ";" _harfbuzz_version_info "${_harfbuzz_version_info}")
+list(GET _harfbuzz_version_info 0
+ _harfbuzz_current)
+list(GET _harfbuzz_version_info 1
+ _harfbuzz_revision)
+list(GET _harfbuzz_version_info 2
+ _harfbuzz_age)
+unset(_harfbuzz_version_info)
+
+if ("@default_library@" MATCHES "static")
+ set(_harfbuzz_lib_suffix ".a")
+else ()
+ if (APPLE)
+ set(_harfbuzz_lib_suffix ".0${CMAKE_SHARED_LIBRARY_SUFFIX}")
+ elseif (UNIX)
+ set(_harfbuzz_lib_suffix "${CMAKE_SHARED_LIBRARY_SUFFIX}.0.${_harfbuzz_current}.${_harfbuzz_revision}")
+ else ()
+ # Unsupported.
+ set(harfbuzz_FOUND 0)
+ endif ()
+endif ()
+
+# Add the libraries.
+add_library(harfbuzz::harfbuzz SHARED IMPORTED)
+set_target_properties(harfbuzz::harfbuzz PROPERTIES
+ INTERFACE_INCLUDE_DIRECTORIES "${_harfbuzz_includedir}/harfbuzz"
+ IMPORTED_LOCATION "${_harfbuzz_libdir}/libharfbuzz${_harfbuzz_lib_suffix}")
+
+add_library(harfbuzz::icu SHARED IMPORTED)
+set_target_properties(harfbuzz::icu PROPERTIES
+ INTERFACE_INCLUDE_DIRECTORIES "${_harfbuzz_includedir}/harfbuzz"
+ INTERFACE_LINK_LIBRARIES "harfbuzz::harfbuzz"
+ IMPORTED_LOCATION "${_harfbuzz_libdir}/libharfbuzz-icu${_harfbuzz_lib_suffix}")
+
+add_library(harfbuzz::subset SHARED IMPORTED)
+set_target_properties(harfbuzz::subset PROPERTIES
+ INTERFACE_INCLUDE_DIRECTORIES "${_harfbuzz_includedir}/harfbuzz"
+ INTERFACE_LINK_LIBRARIES "harfbuzz::harfbuzz"
+ IMPORTED_LOCATION "${_harfbuzz_libdir}/libharfbuzz-subset${_harfbuzz_lib_suffix}")
+
+# Only add the gobject library if it was built.
+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_includedir}/harfbuzz"
+ INTERFACE_LINK_LIBRARIES "harfbuzz::harfbuzz"
+ IMPORTED_LOCATION "${_harfbuzz_libdir}/libharfbuzz-gobject${_harfbuzz_lib_suffix}")
+endif ()
+
+# Clean out variables we used in our scope.
+unset(_harfbuzz_lib_suffix)
+unset(_harfbuzz_current)
+unset(_harfbuzz_revision)
+unset(_harfbuzz_age)
+unset(_harfbuzz_includedir)
+unset(_harfbuzz_libdir)