mirror of
https://github.com/storytold/harfbuzz.git
synced 2026-11-28 17:19:17 +01:00
Some CMake updates for Windows builds (#5997)
* CMake: Fix building hb-gpu on Windows Add the needed items for the program to build and link on Windows in the CMake build files as well. * CMake: Fix introspection builds with ICU Grab the library name from the results of find_package(ICU COMPONENTS uc) and use it instead for linking HarfBuzz, et al, so that we have a proper command line to link to ICU-UC when running g-ir-scanner.
This commit is contained in:
1 parent
f54cb4a3ae
commit
cb3fd656b2
1 file changed
+11
-1
+11
-1
@@ -357,7 +357,8 @@ if (HB_HAVE_ICU)
|
||||
|
||||
list(APPEND project_headers ${PROJECT_SOURCE_DIR}/src/hb-icu.h)
|
||||
|
||||
list(APPEND THIRD_PARTY_LIBS ICU::uc)
|
||||
get_target_property(ICU_UC_LIBRARY ICU::uc IMPORTED_LOCATION)
|
||||
list(APPEND THIRD_PARTY_LIBS ${ICU_UC_LIBRARY})
|
||||
endif ()
|
||||
|
||||
if (APPLE AND HB_HAVE_CORETEXT)
|
||||
@@ -1060,6 +1061,15 @@ if (HB_BUILD_UTILS)
|
||||
"-framework Metal" "-framework QuartzCore"
|
||||
"-framework Foundation" "-framework AppKit")
|
||||
endif ()
|
||||
if (WIN32)
|
||||
find_library(D3D11_LIBRARY NAMES d3d11)
|
||||
find_library(D3DCOMPILER_LIBRARY NAMES d3dcompiler)
|
||||
target_sources(hb-gpu PRIVATE
|
||||
${PROJECT_SOURCE_DIR}/util/gpu/demo-renderer-d3d11.cc)
|
||||
target_link_libraries(hb-gpu
|
||||
"${D3D11_LIBRARY}"
|
||||
"${D3DCOMPILER_LIBRARY}")
|
||||
endif ()
|
||||
endif ()
|
||||
endif ()
|
||||
endif ()
|
||||
|
||||
Reference in new issue
Block a user