#1 Scan /run/host/user-fonts for font files
Merged a month ago by otaylor. Opened 2 months ago by markotaris.
rpms/ markotaris/flatpak-runtime-config user-fonts  into  master

file modified
+12

@@ -1,3 +1,6 @@ 

+ <!-- This should be kept in sync with changes to

+      https://gitlab.com/freedesktop-sdk/freedesktop-sdk/blob/master/files/fontconfig-flatpak.conf

+      from the Freedesktop runtimes. -->

  <?xml version="1.0"?>

  <!DOCTYPE fontconfig SYSTEM "fonts.dtd">

  <fontconfig>

@@ -9,4 +12,13 @@ 

          <include ignore_missing="yes">/app/etc/fonts/local.conf</include>

  

          <dir>/run/host/fonts</dir>

+         <dir>/run/host/user-fonts</dir>

+ 

+         <!-- This is duplicated from the general config because we want to write there

+              before the /run dirs, in case they are ever writable, like e.g with old

+              versions of flatpak. -->

+         <cachedir prefix="xdg">fontconfig</cachedir>

+ 

+         <cachedir>/run/host/fonts-cache</cachedir>

+         <cachedir>/run/host/user-fonts-cache</cachedir>

  </fontconfig>

file modified
+5 -2

@@ -1,6 +1,6 @@ 

  Name:           flatpak-runtime-config

- Version:        29

- Release:        6%{?dist}

+ Version:        30

+ Release:        1%{?dist}

  Summary:        Configuration files that live inside the flatpak runtime

  Source1:        50-flatpak.conf

  Source2:        usercustomize.py

@@ -70,6 +70,9 @@ 

  %{_sysconfdir}/ld.so.conf.d/app.conf

  

  %changelog

+ * Fri Jul 26 2019 Mark Otaris <mark@net-c.com> - 30-1

+ - Update font config to match freedesktop-sdk, allowing user-installed fonts to work

+ 

  * Thu Jul 25 2019 Fedora Release Engineering <releng@fedoraproject.org> - 29-6

  - Rebuilt for https://fedoraproject.org/wiki/Fedora_31_Mass_Rebuild

  

Thanks for investigating and tracking this down! It looks like to me that the fonts.conf file needs a full sync - that is, the part at the bottom with fonts-cache / user-fonts-cache is also relevant. See, e.g.:

https://github.com/flatpak/flatpak/commit/66df733814d0227de029d43c73beb20baa2fb6ae

1 new commit added

  • Add host directories for cache of font information
2 months ago

2 new commits added

  • Add host directories for cache of font information
  • Scan /run/host/user-fonts for font files
2 months ago

Updated to add the font caches.

Can you:

  • Add a comment pointing to the freedesktop-sdk source file that we're copying
  • Also include the <cachedir prefix="xdg">fontconfig</cachedir> line with the comment above it
  • Bump the version-release of flatpak-runtime-config.spec to 30-1 and add a %changelog line like "Update fonts.conf to match freedesktop-sdk, allowing using-installed fonts to work"

You can squash everything together into one big commit, since I don't think it actually breaks apart cleanly.

rebased onto 6855ea6

2 months ago

Updated according to your comments.

Looks great except for one tiny thing. (If you'd prefer I can fix that and push your patch.)

rebased onto c094138

2 months ago

Updated to change the URL. I thought it would break if the file was renamed. However, there is no good solution to that.

rebased onto 2715532

2 months ago

Rebased to fix the merge conflict.

Pull-Request has been merged by otaylor

a month ago