Page MenuHomeFreeBSD

fontconfig: Restore generation of cache prior to Meson switch
ClosedPublic

Authored by diizzy on Aug 18 2021, 9:16 AM.

Details

Summary

This should fix PR 254963 and restore previous behaviour which accidentally got overlooked during the conversion.

Test Plan

Poudriere testport OK 12.2-RELEASE (amd64)

Diff Detail

Repository
R11 FreeBSD ports repository
Lint
Automatic diff as part of commit; lint not applicable.
Unit
Automatic diff as part of commit; unit tests not applicable.

Event Timeline

diizzy created this revision.
diizzy edited the summary of this revision. (Show Details)
diizzy edited the summary of this revision. (Show Details)
diizzy retitled this revision from fontconfig: Restore generation of cache prior to Meson swtich to fontconfig: Restore generation of cache prior to Meson switch.Aug 18 2021, 9:25 AM
x11-fonts/fontconfig/files/patch-fc-cache_meson.build
7

Why this patch is needed? The condition should always be true when building from Ports, as we don't support cross-compilation.

Use SUB_ functions instead manually invoking sed (pointed out by tcberner)

x11-fonts/fontconfig/files/patch-fc-cache_meson.build
7

This seem to cause permission issues when builing as non root https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=254963

x11-fonts/fontconfig/files/patch-fc-cache_meson.build
7

Hum, I wonder if the setting $HOME (to, say, ${WRKDIR}/home) would make it work. If it does, I like this solution more, as it doesn't involve patching.

x11-fonts/fontconfig/files/patch-fc-cache_meson.build
7

Fix typo, depdency --> dependency

x11-fonts/fontconfig/files/patch-fc-cache_meson.build
7

AFAIK, fc-cache tries to write cache files into system directories first and then into $HOME/.cache or something like that. Providing a writable home directory during the build may probably workaround the failure we see.

Alternative patch for fontconfig to work around this issue can be found here:
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=254963#c9
https://gitlab.freedesktop.org/fontconfig/fontconfig/-/issues/296
Is that a better approach?

Yep, this is the best solution.

diizzy edited the test plan for this revision. (Show Details)

Use patch submitted upstream by John Hein (converted using make makepatch)
https://gitlab.freedesktop.org/fontconfig/fontconfig/-/issues/296

This revision is now accepted and ready to land.Sep 6 2021, 5:48 PM