GNU bug report logs -
#41174
Epiphany can't find fonts
Previous Next
To add a comment to this bug, you must first unarchive it, by sending
a message to control AT debbugs.gnu.org, with unarchive 41174 in the body.
You can then email your comments to 41174 AT debbugs.gnu.org in the normal way.
Toggle the display of automated, internal messages from the tracker.
Report forwarded
to
bug-guix <at> gnu.org
:
bug#41174
; Package
guix
.
(Sun, 10 May 2020 13:04:02 GMT)
Full text and
rfc822 format available.
Acknowledgement sent
to
Leo Prikler <leo.prikler <at> student.tugraz.at>
:
New bug report received and forwarded. Copy sent to
bug-guix <at> gnu.org
.
(Sun, 10 May 2020 13:04:02 GMT)
Full text and
rfc822 format available.
Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):
Hi Guix,
when trying to set fonts in Epiphany, it appears as though fonts other
than "Serif", "Sans" and "Monospace" do not apply. Some symbols, such
as CJK, are also missing in text (but not tooltips interestingly) even
if a font supporting them is installed. I tried refreshing and also
removing the fontconfig cache, but that didn't help.
Regards, Leo
Information forwarded
to
bug-guix <at> gnu.org
:
bug#41174
; Package
guix
.
(Mon, 18 May 2020 00:28:02 GMT)
Full text and
rfc822 format available.
Message #8 received at 41174 <at> debbugs.gnu.org (full text, mbox):
Hi Guix,
After some discussion in IRC and testing, I found out that adding
$GUIX_PROFILE/share/fonts to the webkit sandbox (during initialization
via `webkit_web_context_add_path_to_sandbox') resolves this problem. A
more general solution would be to iterate over $XDG_DATA_DIRS, append
`/fonts' to each item and add the resulting path to the sandbox (if it
is a directory).
As this is a problem related to the webkit sandbox, it probably affects
other packages, that make use of it, as well. Looking even deeper
(i.e. diving into the webkitgtk source), it appears that there is
indeed a `bindFonts' procedure in the BubblewrapLauncher, but that only
considers $XDG_DATA_HOME/fonts, not all of $XDG_DATA_DIRS. As this is
the root of the issue, it should probably be fixed there.
Regards,
Leo
Note for those looking for a workaround: Assuming you're installing
your fonts to $GUIX_PROFILE/share/fonts, making $XDG_CACHE_HOME/fonts
or $HOME/.fonts a symlink to that should work.
Information forwarded
to
bug-guix <at> gnu.org
:
bug#41174
; Package
guix
.
(Tue, 26 May 2020 18:16:02 GMT)
Full text and
rfc822 format available.
Message #11 received at 41174 <at> debbugs.gnu.org (full text, mbox):
* gnu/packages/patches/webkitgtk-bind-all-fonts.patch: New file.
* gnu/packages/webkit.scm (webkitgtk)[source]<patches>: Use it here.
* gnu/local.mk: Add it here.
---
gnu/local.mk | 1 +
.../patches/webkitgtk-bind-all-fonts.patch | 37 +++++++++++++++++++
gnu/packages/webkit.scm | 3 +-
3 files changed, 40 insertions(+), 1 deletion(-)
create mode 100644 gnu/packages/patches/webkitgtk-bind-all-fonts.patch
diff --git a/gnu/local.mk b/gnu/local.mk
index d34e7e6ae5..7a694e551a 100644
--- a/gnu/local.mk
+++ b/gnu/local.mk
@@ -1580,6 +1580,7 @@ dist_patch_DATA = \
%D%/packages/patches/warsow-qfusion-fix-bool-return-type.patch \
%D%/packages/patches/weasyprint-library-paths.patch \
%D%/packages/patches/webkitgtk-share-store.patch \
+ %D%/packages/patches/webkitgtk-bind-all-fonts.patch \
%D%/packages/patches/websocketpp-fix-for-boost-1.70.patch \
%D%/packages/patches/wicd-bitrate-none-fix.patch \
%D%/packages/patches/wicd-get-selected-profile-fix.patch \
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..fec0b812f1
--- /dev/null
+++ b/gnu/packages/patches/webkitgtk-bind-all-fonts.patch
@@ -0,0 +1,37 @@
+Add fonts from all XDG_DATA_DIRS, not just XDG_DATA_HOME.
+
+See <http://bugs.gnu.org/41174>.
+Author: Leo Prikler <leo.prikler <at> student.tugraz.at>
+Index: webkitgtk-2.28.2/Source/WebKit/UIProcess/Launcher/glib/BubblewrapLauncher.cpp
+===================================================================
+--- webkitgtk-2.28.2.orig/Source/WebKit/UIProcess/Launcher/glib/BubblewrapLauncher.cpp
++++ webkitgtk-2.28.2/Source/WebKit/UIProcess/Launcher/glib/BubblewrapLauncher.cpp
+@@ -385,8 +385,8 @@ static void bindFonts(Vector<CString>& a
+ {
+ const char* configDir = g_get_user_config_dir();
+ 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));
+@@ -394,15 +394,17 @@ static void bindFonts(Vector<CString>& a
+ GUniquePtr<char> fontCache(g_build_filename(cacheDir, "fontconfig", nullptr));
+ GUniquePtr<char> fontHomeConfig(g_build_filename(homeDir, ".fonts.conf", nullptr));
+ GUniquePtr<char> fontHomeConfigDir(g_build_filename(configDir, ".fonts.conf.d", nullptr));
+- GUniquePtr<char> fontData(g_build_filename(dataDir, "fonts", nullptr));
+ GUniquePtr<char> fontHomeData(g_build_filename(homeDir, ".fonts", nullptr));
+ bindIfExists(args, fontConfig.get());
+ bindIfExists(args, fontConfigHome.get());
+ bindIfExists(args, fontCache.get(), BindFlags::ReadWrite);
+ bindIfExists(args, fontHomeConfig.get());
+ 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.
+ }
diff --git a/gnu/packages/webkit.scm b/gnu/packages/webkit.scm
index 90be7d2625..a5c2b3fee2 100644
--- a/gnu/packages/webkit.scm
+++ b/gnu/packages/webkit.scm
@@ -129,7 +129,8 @@ engine that uses Wayland for graphics output.")
(sha256
(base32
"1g9hik3bprki5s9d7y5288q5irwckbzajr6rnlvjrlnqrwjkblmr"))
- (patches (search-patches "webkitgtk-share-store.patch"))))
+ (patches (search-patches "webkitgtk-share-store.patch"
+ "webkitgtk-bind-all-fonts.patch"))))
(build-system cmake-build-system)
(outputs '("out" "doc"))
(arguments
--
2.26.2
Information forwarded
to
bug-guix <at> gnu.org
:
bug#41174
; Package
guix
.
(Tue, 26 May 2020 19:49:02 GMT)
Full text and
rfc822 format available.
Message #14 received at 41174 <at> debbugs.gnu.org (full text, mbox):
On Tue, 26 May 2020, Leo Prikler wrote:
> * gnu/packages/patches/webkitgtk-bind-all-fonts.patch: New file.
> * gnu/packages/webkit.scm (webkitgtk)[source]<patches>: Use it here.
> * gnu/local.mk: Add it here.
> ---
> gnu/local.mk | 1 +
> .../patches/webkitgtk-bind-all-fonts.patch | 37 +++++++++++++++++++
> gnu/packages/webkit.scm | 3 +-
> 3 files changed, 40 insertions(+), 1 deletion(-)
> create mode 100644 gnu/packages/patches/webkitgtk-bind-all-fonts.patch
Hi,
I tested this patch on my local system, and it seems to resolve the issue
for me. Thanks!
Is this something that should be submitted for inclusion in WebKit
upstream?
Best,
Jack
Information forwarded
to
bug-guix <at> gnu.org
:
bug#41174
; Package
guix
.
(Tue, 26 May 2020 21:57:01 GMT)
Full text and
rfc822 format available.
Message #17 received at 41174 <at> debbugs.gnu.org (full text, mbox):
Am Dienstag, den 26.05.2020, 15:47 -0400 schrieb Jack Hill:
> On Tue, 26 May 2020, Leo Prikler wrote:
>
> > * gnu/packages/patches/webkitgtk-bind-all-fonts.patch: New file.
> > * gnu/packages/webkit.scm (webkitgtk)[source]<patches>: Use it
> > here.
> > * gnu/local.mk: Add it here.
> > ---
> > gnu/local.mk | 1 +
> > .../patches/webkitgtk-bind-all-fonts.patch | 37
> > +++++++++++++++++++
> > gnu/packages/webkit.scm | 3 +-
> > 3 files changed, 40 insertions(+), 1 deletion(-)
> > create mode 100644 gnu/packages/patches/webkitgtk-bind-all-
> > fonts.patch
>
> Hi,
>
> I tested this patch on my local system, and it seems to resolve the
> issue
> for me. Thanks!
>
> Is this something that should be submitted for inclusion in WebKit
> upstream?
>
> Best,
> Jack
Hi,
I don't see anything in the patch itself, that is specific to Guix, so
it should probably work upstream as well. This issue is likely going
to affect other functional package managers like Nix too, so it would
be nice, if we can get the patch to be accepted upstream. However, it
does add a specific exception just for fonts, while other resources are
still taken from XDG_DATA_HOME. As such, it is still rather an ad-hoc
solution to a very specific annoyance than something "general".
I'm also not quite sure, whether this could cause problems with the
number of arguments being passed to the bwrap process exceeding some
limit. It has not yet come up so far, but I thought I'd mention it.
However, if it does, we're going to be the first to notice with our
huge environment variables, so that's probably a bigger deal here than
elsewhere.
Regards,
Leo
Information forwarded
to
bug-guix <at> gnu.org
:
bug#41174
; Package
guix
.
(Wed, 27 May 2020 01:20:01 GMT)
Full text and
rfc822 format available.
Message #20 received at 41174 <at> debbugs.gnu.org (full text, mbox):
On Tue, 26 May 2020, Leo Prikler wrote:
> Hi,
>
> I don't see anything in the patch itself, that is specific to Guix, so
> it should probably work upstream as well. This issue is likely going
> to affect other functional package managers like Nix too, so it would
> be nice, if we can get the patch to be accepted upstream. However, it
> does add a specific exception just for fonts, while other resources are
> still taken from XDG_DATA_HOME. As such, it is still rather an ad-hoc
> solution to a very specific annoyance than something "general".
Ah, I see. I missed the special exception for fonts.
> I'm also not quite sure, whether this could cause problems with the
> number of arguments being passed to the bwrap process exceeding some
> limit. It has not yet come up so far, but I thought I'd mention it.
> However, if it does, we're going to be the first to notice with our
> huge environment variables, so that's probably a bigger deal here than
> elsewhere.
I don't think this should be a problem. bwrap supports having its
arguments passed over a file describer (with the --args option), and this
is what WebKitGTK does.
Best,
Jack
Information forwarded
to
bug-guix <at> gnu.org
:
bug#41174
; Package
guix
.
(Sun, 02 Aug 2020 10:07:02 GMT)
Full text and
rfc822 format available.
Message #23 received at 41174 <at> debbugs.gnu.org (full text, mbox):
I'm not sure whether the warnings generated are related to the
behaviour you're experiencing. There is a way of forcing Epiphany to
use another locale for a website, so perhaps you can try that.
In relation to displaying text correctly, I already reported 41174 and
have not noticed it being fixed since.
Regards,
Leo
Full quote for ML readers:
> Using guix 1.1.0
>
> guix (GNU Guix) 2621c6a9ea726cd57c39317329575b7b9fdd7b96
>
> error:
> @guix ~$ epiphany
>
> ** (epiphany:1968): CRITICAL **: 20:43:43.285: void
> webkit_web_context_register_uri_scheme(WebKitWebContext*, const
> char*,
> WebKitURISchemeRequestCallback, gpointer, GDestroyNotify): assertion
> 'g_ascii_strcasecmp(scheme, "ftp") != 0' failed
>
> (process:2): Gtk-WARNING **: 20:43:45.107: Locale not supported by C
> library.
> Using the fallback 'C' locale.
>
> (process:2): Gtk-WARNING **: 20:43:45.117: Locale not supported by C
> library.
> Using the fallback 'C' locale.
>
> (process:2): Gtk-WARNING **: 20:43:45.458: Locale not supported by C
> library.
> Using the fallback 'C' locale.
>
> (process:2): Gtk-WARNING **: 20:43:45.573: Locale not supported by C
> library.
> Using the fallback 'C' locale.
>
> (process:2): Gtk-WARNING **: 20:43:45.848: Locale not supported by C
> library.
> Using the fallback 'C' locale.
>
> (process:2): Gtk-WARNING **: 20:43:45.915: Locale not supported by C
> library.
> Using the fallback 'C' locale.
>
> (process:2): Gtk-WARNING **: 20:43:46.093: Locale not supported by C
> library.
> Using the fallback 'C' locale.
>
> =======
> using nyxt browser, the Chinese is displayed correctly.
>
> How can I fix this?
>
> best regards,
> wxie
Information forwarded
to
bug-guix <at> gnu.org
:
bug#41174
; Package
guix
.
(Sun, 02 Aug 2020 14:03:02 GMT)
Full text and
rfc822 format available.
Message #26 received at 41174 <at> debbugs.gnu.org (full text, mbox):
Thank you, Leo.
What's the way to force Epiphany to use another locale for web?
best regards,
wxie
On 2020/8/2 下午6:05, Leo Prikler wrote:
> I'm not sure whether the warnings generated are related to the
> behaviour you're experiencing. There is a way of forcing Epiphany to
> use another locale for a website, so perhaps you can try that.
>
> In relation to displaying text correctly, I already reported 41174 and
> have not noticed it being fixed since.
>
> Regards,
> Leo
>
> Full quote for ML readers:
>> Using guix 1.1.0
>>
>> guix (GNU Guix) 2621c6a9ea726cd57c39317329575b7b9fdd7b96
>>
>> error:
>> @guix ~$ epiphany
>>
>> ** (epiphany:1968): CRITICAL **: 20:43:43.285: void
>> webkit_web_context_register_uri_scheme(WebKitWebContext*, const
>> char*,
>> WebKitURISchemeRequestCallback, gpointer, GDestroyNotify): assertion
>> 'g_ascii_strcasecmp(scheme, "ftp") != 0' failed
>>
>> (process:2): Gtk-WARNING **: 20:43:45.107: Locale not supported by C
>> library.
>> Using the fallback 'C' locale.
>>
>> (process:2): Gtk-WARNING **: 20:43:45.117: Locale not supported by C
>> library.
>> Using the fallback 'C' locale.
>>
>> (process:2): Gtk-WARNING **: 20:43:45.458: Locale not supported by C
>> library.
>> Using the fallback 'C' locale.
>>
>> (process:2): Gtk-WARNING **: 20:43:45.573: Locale not supported by C
>> library.
>> Using the fallback 'C' locale.
>>
>> (process:2): Gtk-WARNING **: 20:43:45.848: Locale not supported by C
>> library.
>> Using the fallback 'C' locale.
>>
>> (process:2): Gtk-WARNING **: 20:43:45.915: Locale not supported by C
>> library.
>> Using the fallback 'C' locale.
>>
>> (process:2): Gtk-WARNING **: 20:43:46.093: Locale not supported by C
>> library.
>> Using the fallback 'C' locale.
>>
>> =======
>> using nyxt browser, the Chinese is displayed correctly.
>>
>> How can I fix this?
>>
>> best regards,
>> wxie
Information forwarded
to
bug-guix <at> gnu.org
:
bug#41174
; Package
guix
.
(Sun, 02 Aug 2020 14:07:02 GMT)
Full text and
rfc822 format available.
Message #29 received at 41174 <at> debbugs.gnu.org (full text, mbox):
I'm not quite sure how it's called in your language, but you can set an
encoding using the fifth button from below in the main menu.
Am Sonntag, den 02.08.2020, 22:02 +0800 schrieb Wensheng Xie:
> Thank you, Leo.
>
>
> What's the way to force Epiphany to use another locale for web?
>
>
> best regards,
>
> wxie
>
> On 2020/8/2 下午6:05, Leo Prikler wrote:
> > I'm not sure whether the warnings generated are related to the
> > behaviour you're experiencing. There is a way of forcing Epiphany
> > to
> > use another locale for a website, so perhaps you can try that.
> >
> > In relation to displaying text correctly, I already reported 41174
> > and
> > have not noticed it being fixed since.
> >
> > Regards,
> > Leo
> >
> > Full quote for ML readers:
> > > Using guix 1.1.0
> > >
> > > guix (GNU Guix) 2621c6a9ea726cd57c39317329575b7b9fdd7b96
> > >
> > > error:
> > > @guix ~$ epiphany
> > >
> > > ** (epiphany:1968): CRITICAL **: 20:43:43.285: void
> > > webkit_web_context_register_uri_scheme(WebKitWebContext*, const
> > > char*,
> > > WebKitURISchemeRequestCallback, gpointer, GDestroyNotify):
> > > assertion
> > > 'g_ascii_strcasecmp(scheme, "ftp") != 0' failed
> > >
> > > (process:2): Gtk-WARNING **: 20:43:45.107: Locale not supported
> > > by C
> > > library.
> > > Using the fallback 'C' locale.
> > >
> > > (process:2): Gtk-WARNING **: 20:43:45.117: Locale not supported
> > > by C
> > > library.
> > > Using the fallback 'C' locale.
> > >
> > > (process:2): Gtk-WARNING **: 20:43:45.458: Locale not supported
> > > by C
> > > library.
> > > Using the fallback 'C' locale.
> > >
> > > (process:2): Gtk-WARNING **: 20:43:45.573: Locale not supported
> > > by C
> > > library.
> > > Using the fallback 'C' locale.
> > >
> > > (process:2): Gtk-WARNING **: 20:43:45.848: Locale not supported
> > > by C
> > > library.
> > > Using the fallback 'C' locale.
> > >
> > > (process:2): Gtk-WARNING **: 20:43:45.915: Locale not supported
> > > by C
> > > library.
> > > Using the fallback 'C' locale.
> > >
> > > (process:2): Gtk-WARNING **: 20:43:46.093: Locale not supported
> > > by C
> > > library.
> > > Using the fallback 'C' locale.
> > >
> > > =======
> > > using nyxt browser, the Chinese is displayed correctly.
> > >
> > > How can I fix this?
> > >
> > > best regards,
> > > wxie
Information forwarded
to
bug-guix <at> gnu.org
:
bug#41174
; Package
guix
.
(Sun, 02 Aug 2020 14:12:01 GMT)
Full text and
rfc822 format available.
Message #32 received at 41174 <at> debbugs.gnu.org (full text, mbox):
I had tried that for all possibility, and none had worked.
This is so strange.
On 2020/8/2 下午10:06, Leo Prikler wrote:
> I'm not quite sure how it's called in your language, but you can set an
> encoding using the fifth button from below in the main menu.
>
> Am Sonntag, den 02.08.2020, 22:02 +0800 schrieb Wensheng Xie:
>> Thank you, Leo.
>>
>>
>> What's the way to force Epiphany to use another locale for web?
>>
>>
>> best regards,
>>
>> wxie
>>
>> On 2020/8/2 下午6:05, Leo Prikler wrote:
>>> I'm not sure whether the warnings generated are related to the
>>> behaviour you're experiencing. There is a way of forcing Epiphany
>>> to
>>> use another locale for a website, so perhaps you can try that.
>>>
>>> In relation to displaying text correctly, I already reported 41174
>>> and
>>> have not noticed it being fixed since.
>>>
>>> Regards,
>>> Leo
>>>
>>> Full quote for ML readers:
>>>> Using guix 1.1.0
>>>>
>>>> guix (GNU Guix) 2621c6a9ea726cd57c39317329575b7b9fdd7b96
>>>>
>>>> error:
>>>> @guix ~$ epiphany
>>>>
>>>> ** (epiphany:1968): CRITICAL **: 20:43:43.285: void
>>>> webkit_web_context_register_uri_scheme(WebKitWebContext*, const
>>>> char*,
>>>> WebKitURISchemeRequestCallback, gpointer, GDestroyNotify):
>>>> assertion
>>>> 'g_ascii_strcasecmp(scheme, "ftp") != 0' failed
>>>>
>>>> (process:2): Gtk-WARNING **: 20:43:45.107: Locale not supported
>>>> by C
>>>> library.
>>>> Using the fallback 'C' locale.
>>>>
>>>> (process:2): Gtk-WARNING **: 20:43:45.117: Locale not supported
>>>> by C
>>>> library.
>>>> Using the fallback 'C' locale.
>>>>
>>>> (process:2): Gtk-WARNING **: 20:43:45.458: Locale not supported
>>>> by C
>>>> library.
>>>> Using the fallback 'C' locale.
>>>>
>>>> (process:2): Gtk-WARNING **: 20:43:45.573: Locale not supported
>>>> by C
>>>> library.
>>>> Using the fallback 'C' locale.
>>>>
>>>> (process:2): Gtk-WARNING **: 20:43:45.848: Locale not supported
>>>> by C
>>>> library.
>>>> Using the fallback 'C' locale.
>>>>
>>>> (process:2): Gtk-WARNING **: 20:43:45.915: Locale not supported
>>>> by C
>>>> library.
>>>> Using the fallback 'C' locale.
>>>>
>>>> (process:2): Gtk-WARNING **: 20:43:46.093: Locale not supported
>>>> by C
>>>> library.
>>>> Using the fallback 'C' locale.
>>>>
>>>> =======
>>>> using nyxt browser, the Chinese is displayed correctly.
>>>>
>>>> How can I fix this?
>>>>
>>>> best regards,
>>>> wxie
Reply sent
to
Maxim Cournoyer <maxim.cournoyer <at> gmail.com>
:
You have taken responsibility.
(Sun, 16 Aug 2020 20:21:01 GMT)
Full text and
rfc822 format available.
Notification sent
to
Leo Prikler <leo.prikler <at> student.tugraz.at>
:
bug acknowledged by developer.
(Sun, 16 Aug 2020 20:21:02 GMT)
Full text and
rfc822 format available.
Message #37 received at 41174-done <at> debbugs.gnu.org (full text, mbox):
[Message part 1 (text/plain, inline)]
Hi Leo,
Leo Prikler <leo.prikler <at> student.tugraz.at> writes:
> * gnu/packages/patches/webkitgtk-bind-all-fonts.patch: New file.
> * gnu/packages/webkit.scm (webkitgtk)[source]<patches>: Use it here.
> * gnu/local.mk: Add it here.
I've expounded a bit the commit message,
> ---
> gnu/local.mk | 1 +
> .../patches/webkitgtk-bind-all-fonts.patch | 37 +++++++++++++++++++
> gnu/packages/webkit.scm | 3 +-
> 3 files changed, 40 insertions(+), 1 deletion(-)
> create mode 100644 gnu/packages/patches/webkitgtk-bind-all-fonts.patch
>
> diff --git a/gnu/local.mk b/gnu/local.mk
> index d34e7e6ae5..7a694e551a 100644
> --- a/gnu/local.mk
> +++ b/gnu/local.mk
> @@ -1580,6 +1580,7 @@ dist_patch_DATA = \
> %D%/packages/patches/warsow-qfusion-fix-bool-return-type.patch \
> %D%/packages/patches/weasyprint-library-paths.patch \
> %D%/packages/patches/webkitgtk-share-store.patch \
> + %D%/packages/patches/webkitgtk-bind-all-fonts.patch \
> %D%/packages/patches/websocketpp-fix-for-boost-1.70.patch \
> %D%/packages/patches/wicd-bitrate-none-fix.patch \
> %D%/packages/patches/wicd-get-selected-profile-fix.patch \
> 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..fec0b812f1
> --- /dev/null
> +++ b/gnu/packages/patches/webkitgtk-bind-all-fonts.patch
> @@ -0,0 +1,37 @@
> +Add fonts from all XDG_DATA_DIRS, not just XDG_DATA_HOME.
> +
> +See <http://bugs.gnu.org/41174>.
> +Author: Leo Prikler <leo.prikler <at> student.tugraz.at>
> +Index: webkitgtk-2.28.2/Source/WebKit/UIProcess/Launcher/glib/BubblewrapLauncher.cpp
> +===================================================================
> +--- webkitgtk-2.28.2.orig/Source/WebKit/UIProcess/Launcher/glib/BubblewrapLauncher.cpp
> ++++ webkitgtk-2.28.2/Source/WebKit/UIProcess/Launcher/glib/BubblewrapLauncher.cpp
> +@@ -385,8 +385,8 @@ static void bindFonts(Vector<CString>& a
> + {
> + const char* configDir = g_get_user_config_dir();
> + 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));
> +@@ -394,15 +394,17 @@ static void bindFonts(Vector<CString>& a
> + GUniquePtr<char> fontCache(g_build_filename(cacheDir, "fontconfig", nullptr));
> + GUniquePtr<char> fontHomeConfig(g_build_filename(homeDir, ".fonts.conf", nullptr));
> + GUniquePtr<char> fontHomeConfigDir(g_build_filename(configDir, ".fonts.conf.d", nullptr));
> +- GUniquePtr<char> fontData(g_build_filename(dataDir, "fonts", nullptr));
> + GUniquePtr<char> fontHomeData(g_build_filename(homeDir, ".fonts", nullptr));
> + bindIfExists(args, fontConfig.get());
> + bindIfExists(args, fontConfigHome.get());
> + bindIfExists(args, fontCache.get(), BindFlags::ReadWrite);
> + bindIfExists(args, fontHomeConfig.get());
> + bindIfExists(args, fontHomeConfigDir.get());
> +- bindIfExists(args, fontData.get());
removed the above deleted lines from your patch, so as to continue
honoring XDG_DATA_HOME,
> + 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.
> + }
> diff --git a/gnu/packages/webkit.scm b/gnu/packages/webkit.scm
> index 90be7d2625..a5c2b3fee2 100644
> --- a/gnu/packages/webkit.scm
> +++ b/gnu/packages/webkit.scm
> @@ -129,7 +129,8 @@ engine that uses Wayland for graphics output.")
> (sha256
> (base32
> "1g9hik3bprki5s9d7y5288q5irwckbzajr6rnlvjrlnqrwjkblmr"))
> - (patches (search-patches "webkitgtk-share-store.patch"))))
> + (patches (search-patches "webkitgtk-share-store.patch"
> + "webkitgtk-bind-all-fonts.patch"))))
> (build-system cmake-build-system)
> (outputs '("out" "doc"))
> (arguments
And validated it worked well with a './pre-inst-env guix system vm
epiphany-ratpoison.scm' generated VM (it exhibited the problem after
all, when used in a VM).
For completeness sake, the test VM operating system is attached. It's
not necessary to include bubblewrap to trigger the font problem.
[epiphany-ratpoison.scm (text/plain, attachment)]
[Message part 3 (text/plain, inline)]
The fix is now merged in master as of commit bc549a276c.
Thanks for investigating and fixing the issue!
Closing,
Maxim
bug archived.
Request was from
Debbugs Internal Request <help-debbugs <at> gnu.org>
to
internal_control <at> debbugs.gnu.org
.
(Mon, 14 Sep 2020 11:24:07 GMT)
Full text and
rfc822 format available.
This bug report was last modified 3 years and 217 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.