From c3c759cbddfe48a4253b5e9c6cb7817b862caeef Mon Sep 17 00:00:00 2001 From: Chun-wei Fan Date: Thu, 25 Nov 2021 12:39:39 +0800 Subject: [PATCH] Visual Studio projects: Define __MSVC_PROJECTS__ ...in the libgtk3 project, so that we can automatically link to harfbuzz.lib if we have a sufficiently-new version of Pango and HarfBuzz installed, so that the code to enable font features can be linked properly, even if we don't explicitly put harfbuzz.lib in the list of libraries that we feed into the linker in the project files. If one is using pre-Pango-1.44.x and/or pre-HarfBuzz-2.2.0 and intends to enable font features support, one still must update config.h.win32 to make sure HAVE_PANGOFT2 and HAVE_HARFBUZZ is defined, and put pangoft2-1.0.lib, harfbuzz.lib and freetype.lib (or so) in the "Additional Libraries" under the linker settings in the projects manually, as required before. --- win32/vs10/gtk3-build-defines.props | 2 +- win32/vs9/gtk3-build-defines.vsprops | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/win32/vs10/gtk3-build-defines.props b/win32/vs10/gtk3-build-defines.props index 50c8cf6fbe..4fddda3189 100644 --- a/win32/vs10/gtk3-build-defines.props +++ b/win32/vs10/gtk3-build-defines.props @@ -12,7 +12,7 @@ i686 x86_64 aarch64 - GTK_COMPILATION;G_LOG_DOMAIN="Gtk";GTK_HOST="$(GtkHostMachine)-pc-vs$(VSVer)";GTK_PRINT_BACKENDS="file";GTK_PRINT_BACKEND_ENABLE_UNSUPPORTED;$(GtkIncludedImmodulesDefines);GTK_LIBDIR="$(GtkDummyPrefix)/lib";GTK_DATADIR="$(GtkDummyPrefix)/share";GTK_DATA_PREFIX="$(GtkDummyPrefix)";GTK_SYSCONFDIR="$(GtkDummyPrefix)/etc";MULTIPRESS_CONFDIR="$(GtkDummyPrefix)/etc/gtk-$(ApiVersion)";MULTIPRESS_LOCALEDIR="$(GtkDummyPrefix)/share/locale";GTK_VERSION="$(GtkVersion)/etc";GTK_BINARY_VERSION="$(GtkBinaryVersion)/etc";GDK_DISABLE_DEPRECATED;ISOLATION_AWARE_ENABLED + GTK_COMPILATION;G_LOG_DOMAIN="Gtk";GTK_HOST="$(GtkHostMachine)-pc-vs$(VSVer)";GTK_PRINT_BACKENDS="file";GTK_PRINT_BACKEND_ENABLE_UNSUPPORTED;$(GtkIncludedImmodulesDefines);GTK_LIBDIR="$(GtkDummyPrefix)/lib";GTK_DATADIR="$(GtkDummyPrefix)/share";GTK_DATA_PREFIX="$(GtkDummyPrefix)";GTK_SYSCONFDIR="$(GtkDummyPrefix)/etc";MULTIPRESS_CONFDIR="$(GtkDummyPrefix)/etc/gtk-$(ApiVersion)";MULTIPRESS_LOCALEDIR="$(GtkDummyPrefix)/share/locale";GTK_VERSION="$(GtkVersion)/etc";GTK_BINARY_VERSION="$(GtkBinaryVersion)/etc";GDK_DISABLE_DEPRECATED;ISOLATION_AWARE_ENABLED;__MSVC_PROJECTS__ ole32.lib;advapi32.lib;shell32.lib;gdi32.lib pangowin32-1.0.lib;fribidi.lib;imm32.lib;$(CommonARM64SystemLibs) winmm.lib;dwmapi.lib;setupapi.lib;hid.lib;$(GtkGdkCommonLibs) diff --git a/win32/vs9/gtk3-build-defines.vsprops b/win32/vs9/gtk3-build-defines.vsprops index e47c348063..876e2406cc 100644 --- a/win32/vs9/gtk3-build-defines.vsprops +++ b/win32/vs9/gtk3-build-defines.vsprops @@ -41,11 +41,11 @@ />