summaryrefslogtreecommitdiff
path: root/gnu/packages/patches/webkitgtk-bind-all-fonts.patch
diff options
context:
space:
mode:
authorMathieu Othacehe <othacehe@gnu.org>2020-08-26 18:35:14 +0200
committerMathieu Othacehe <othacehe@gnu.org>2020-08-26 18:35:14 +0200
commit17dddeeee560527a8f30d37761949d658056cb09 (patch)
tree15b0b19c55787f556eb9b42c28d173bddc5435db /gnu/packages/patches/webkitgtk-bind-all-fonts.patch
parent331a09654eb7e9f6212b7e8469077fa7393e8b11 (diff)
parent6a9581741e4ee81226aeb2f1c997df76670a6aab (diff)
downloadguix-patches-17dddeeee560527a8f30d37761949d658056cb09.tar
guix-patches-17dddeeee560527a8f30d37761949d658056cb09.tar.gz
Merge remote-tracking branch 'origin/master' into core-updates
Diffstat (limited to 'gnu/packages/patches/webkitgtk-bind-all-fonts.patch')
-rw-r--r--gnu/packages/patches/webkitgtk-bind-all-fonts.patch26
1 files changed, 26 insertions, 0 deletions
diff --git a/gnu/packages/patches/webkitgtk-bind-all-fonts.patch b/gnu/packages/patches/webkitgtk-bind-all-fonts.patch
new file mode 100644
index 0000000000..3fe9704727
--- /dev/null
+++ b/gnu/packages/patches/webkitgtk-bind-all-fonts.patch
@@ -0,0 +1,26 @@
+Add fonts from all XDG_DATA_DIRS, not just XDG_DATA_HOME.
+
+See <http://bugs.gnu.org/41174>.
+Author: Leo Prikler <leo.prikler@student.tugraz.at>
+Index: webkitgtk-2.28.2/Source/WebKit/UIProcess/Launcher/glib/BubblewrapLauncher.cpp
+===================================================================
+--- a/Source/WebKit/UIProcess/Launcher/glib/BubblewrapLauncher.cpp
++++ b/Source/WebKit/UIProcess/Launcher/glib/BubblewrapLauncher.cpp
+@@ -387,6 +387,7 @@ static void bindFonts(Vector<CString>& args)
+ const char* homeDir = g_get_home_dir();
+ const char* dataDir = g_get_user_data_dir();
+ const char* cacheDir = g_get_user_cache_dir();
++ const char* const * dataDirs = g_get_system_data_dirs();
+
+ // Configs can include custom dirs but then we have to parse them...
+ GUniquePtr<char> fontConfig(g_build_filename(configDir, "fontconfig", nullptr));
+@@ -403,6 +404,10 @@ static void bindFonts(Vector<CString>& args)
+ bindIfExists(args, fontHomeConfigDir.get());
+ bindIfExists(args, fontData.get());
+ bindIfExists(args, fontHomeData.get());
++ for (auto dataDir = dataDirs; dataDir != nullptr && *dataDir != nullptr; dataDir++) {
++ GUniquePtr<char> fontDataDir(g_build_filename(*dataDir, "fonts", nullptr));
++ bindIfExists(args, fontDataDir.get());
++ }
+ bindIfExists(args, "/var/cache/fontconfig"); // Used by Debian.
+ }