summaryrefslogtreecommitdiff
path: root/Build/source/libs/gd/TLpatches/patch-01-win32
diff options
context:
space:
mode:
authorKarl Berry <karl@freefriends.org>2017-02-13 22:32:47 +0000
committerKarl Berry <karl@freefriends.org>2017-02-13 22:32:47 +0000
commit370b138f85fb5eee6e176bcd9ad772ba178cb843 (patch)
tree8a61482b1002160dab258c9dc051c14abd2ab46d /Build/source/libs/gd/TLpatches/patch-01-win32
parent11e8da1007c229802798bcb15cc69c62f5b8e5f6 (diff)
TLpatches seems nicer than all uppercase; sorry for churn
git-svn-id: svn://tug.org/texlive/trunk@43214 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Build/source/libs/gd/TLpatches/patch-01-win32')
-rw-r--r--Build/source/libs/gd/TLpatches/patch-01-win3220
1 files changed, 20 insertions, 0 deletions
diff --git a/Build/source/libs/gd/TLpatches/patch-01-win32 b/Build/source/libs/gd/TLpatches/patch-01-win32
new file mode 100644
index 00000000000..814ed38e1e9
--- /dev/null
+++ b/Build/source/libs/gd/TLpatches/patch-01-win32
@@ -0,0 +1,20 @@
+diff -ur libgd-2.2.4.orig/src/gdft.c libgd-2.2.4/src/gdft.c
+--- libgd-2.2.4.orig/src/gdft.c Wed Jan 18 20:01:19 2017
++++ libgd-2.2.4/src/gdft.c Thu Jan 19 07:20:24 2017
+@@ -1683,6 +1683,16 @@
+ */
+ *fontpath = NULL;
+ fontsearchpath = getenv ("GDFONTPATH");
++#ifdef _WIN32
++ if (!fontsearchpath) {
++ char *ffptr = getenv ("SYSTEMROOT");
++ if (ffptr) {
++ fontsearchpath = malloc (strlen(ffptr) + strlen("\\fonts") + 1);
++ strcpy(fontsearchpath, ffptr);
++ strcat(fontsearchpath, "\\fonts");
++ }
++ }
++#endif
+ if (!fontsearchpath)
+ fontsearchpath = DEFAULT_FONTPATH;
+ path = (char *) gdMalloc(sizeof(char) * strlen(fontsearchpath) + 1);