1
0
mirror of https://git.FreeBSD.org/ports.git synced 2024-10-18 19:49:40 +00:00

print/fontforge: Fix timeout without GUI

Add an upstream patch to fix a timeout when starting fontforge without any
gui available, such as when running fontforge -version.  This fixes delays
when building for instance print/lilypond.

PR:		240680
Approved by:	Naram Qashat
This commit is contained in:
Niclas Zeising 2019-09-19 14:11:04 +00:00
parent 7800d020d8
commit 05dae60737
Notes: svn2git 2021-03-31 03:12:20 +00:00
svn path=/head/; revision=512342
2 changed files with 26 additions and 1 deletions

View File

@ -3,7 +3,7 @@
PORTNAME= fontforge
PORTVERSION= 20190801
PORTREVISION= 1
PORTREVISION= 2
CATEGORIES= print
MAINTAINER= cyberbotx@cyberbotx.com

View File

@ -0,0 +1,25 @@
--- fontforgeexe/startui.c.orig 2019-08-01 08:28:36 UTC
+++ fontforgeexe/startui.c
@@ -1099,10 +1099,6 @@ int fontforge_main( int argc, char **argv ) {
CheckIsScript(argc,argv); /* Will run the script and exit if it is a script */
/* If there is no UI, there is always a script */
/* and we will never return from the above */
-#ifdef FONTFORGE_CAN_USE_GDK
- gdk_init(&argc, &argv);
- gdk_set_allowed_backends("win32,quartz,x11");
-#endif
if ( load_prefs==NULL ||
(strcasecmp(load_prefs,"Always")!=0 && /* Already loaded */
strcasecmp(load_prefs,"Never")!=0 ))
@@ -1185,7 +1181,10 @@ int fontforge_main( int argc, char **argv ) {
}
#endif
}
-
+#ifdef FONTFORGE_CAN_USE_GDK
+ gdk_init(&argc, &argv);
+ gdk_set_allowed_backends("win32,quartz,x11");
+#endif
ensureDotFontForgeIsSetup();
#if defined(__MINGW32__) && !defined(_NO_LIBCAIRO)
//Load any custom fonts for the user interface