diff --git a/CMakeLists.txt b/CMakeLists.txt index c3e568fe3..3b4f5aa61 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -334,15 +334,15 @@ endif () if (WIN32 AND HB_HAVE_GDI) add_definitions(-DHAVE_GDI) list(APPEND project_headers ${PROJECT_SOURCE_DIR}/src/hb-gdi.h) - list(APPEND THIRD_PARTY_LIBS gdi32) - list(APPEND PC_LIBS_PRIV -lgdi32) + list(APPEND THIRD_PARTY_LIBS gdi32 user32) + list(APPEND PC_LIBS_PRIV -lgdi32 -luser32) endif () if (WIN32 AND HB_HAVE_UNISCRIBE) add_definitions(-DHAVE_UNISCRIBE) list(APPEND project_headers ${PROJECT_SOURCE_DIR}/src/hb-uniscribe.h) - list(APPEND THIRD_PARTY_LIBS usp10 gdi32 rpcrt4) - list(APPEND PC_LIBS_PRIV -lusp10 -lgdi32 -lrpcrt4) + list(APPEND THIRD_PARTY_LIBS usp10 gdi32 rpcrt4 user32) + list(APPEND PC_LIBS_PRIV -lusp10 -lgdi32 -lrpcrt4 -luser32) endif () if (WIN32 AND HB_HAVE_DIRECTWRITE) diff --git a/meson.build b/meson.build index 1eeec4291..863f0a860 100644 --- a/meson.build +++ b/meson.build @@ -321,7 +321,7 @@ if host_machine.system() == 'windows' and not get_option('gdi').disabled() endif gdi_deps_found = true - foreach usplib : ['usp10', 'gdi32', 'rpcrt4'] + foreach usplib : ['usp10', 'gdi32', 'rpcrt4', 'user32'] dep = cpp.find_library(usplib, required: get_option('gdi')) gdi_deps_found = gdi_deps_found and dep.found() gdi_uniscribe_deps += dep