https://bugzilla.redhat.com/show_bug.cgi?id=1806272
--- Comment #24 from Hans de Goede hdegoede@redhat.com --- Thank you for adding the compat packages.
I must be honest though, this is not entirely what I was expecting. I was expecting the compat symlinks to be part of the main dejavu-sans-fonts, dejavu-serif-fonts, etc. packages. That way they will automatically just be there, without packages depending on say dejavu-sans-fonts needing to adjust their Requires. If someone needs to go my specfile changes to adjust the Requires (and do a build and create an update in bodhi) they might just as well fix the paths and be done with it.
I guess the compat packages are still useful though as a quick fix/workaround which users can install themselves in case of pkgs where no one has gotten around to fixing them.
Talking about fixing packages. I've spend some time thinking about how to fix things. Most affected packages are games, typically using SDL[2]_ttf which requires a direct file-path to a ttf file. Typically the fonts are bundled together with other game-assets, living under /usr/share/<game-name>/font.ttf . The Fedora pkgs replace font.ttf with a symlink, either because the font was removed because it was non-free, or to use system-fonts instead of shipping a private copy.
For these games my plan is to add e.g.:
BuildRequires: font(dejavusans) fontconfig
To the packages and then generate the name the symlink points to using commands like these:
fc-match -f "%{file}" "sans" fc-match -f "%{file}" "sans:italic" fc-match -f "%{file}" "sans:bold" fc-match -f "%{file}" "sans:bold:italic" fc-match -f "%{file}" "serif" fc-match -f "%{file}" "monospace"
The idea here is to make things more future proof, so that we can deal with any future font-file-path changes with just a rebuild.
Before I spend a chunk of time on fixing various packages, I would appreciate your feedback on this approach. Do you think that this is a good idea? Any suggestions wrt the fc-match commands?