1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
|
From 0103e0e07f3cfd1a1e426b63354881cc547022e1 Mon Sep 17 00:00:00 2001
From: Matt Jolly <kangie@gentoo.org>
Date: Sat, 20 Sep 2025 11:47:38 +1000
Subject: [PATCH] build with actually released fontconfig
https://chromium.googlesource.com/chromium/src/+/9af749d9dfb0f4a5aaa0463bcad126973e3d5363
rolls Chromium's fontconfig to include
https://chromium.googlesource.com/external/fontconfig.git/+/59da606145558a0041eb90d9c80a26a6f0c1d348%5E%21/
which _is_ available upstream, but is not in _any_ fontconfig release;
this change updates the fontconfig cache magic number from `9` to `10`.
As a result, any Chromium build using an unbundled fontconfig (like, say,
every Linux distro...) will fail if building test targets, despite fontconfig
being one of the few libraries supported by
`build/linux/unbundle/replace_gn_files.py`.
Further changes to work around regressions in fontations also configure bundled
fontconfig to suffix `-reindex1` to the cache path which, as per the above, also
breaks builds using system fontconfig.
https://github.com/chromium/chromium/commit/bbf7b467a342847e94eadf02777ab70073807fa7
And further changes in M142 have bumped the cache version to `11`. Hopefully this stabilises
soon and fontconfig gets a release.
This patch reverts enough of these changes to allow Chromium to build with
unbundled (and actually released) fontconfig versions again.
See-also: https://issues.chromium.org/issues/442698344
Signed-off-by: Matt Jolly <kangie@gentoo.org>
--- a/third_party/test_fonts/fontconfig/BUILD.gn
+++ b/third_party/test_fonts/fontconfig/BUILD.gn
@@ -49,7 +49,7 @@ if (is_linux || is_chromeos) {
args = []
inputs = [ "$root_out_dir/etc/fonts/fonts.conf" ]
outputs = [
- "$root_out_dir/fontconfig_caches/fb5c91b2895aa445d23aebf7f9e2189c-le64.cache-11",
+ "$root_out_dir/fontconfig_caches/fb5c91b2895aa445d23aebf7f9e2189c-le64.cache-9",
"$root_out_dir/fontconfig_caches/CACHEDIR.TAG",
]
}
--- a/third_party/test_fonts/fontconfig/generate_fontconfig_caches.cc
+++ b/third_party/test_fonts/fontconfig/generate_fontconfig_caches.cc
@@ -56,7 +56,7 @@ int main() {
FcFini();
// Check existence of intended fontconfig cache file.
- auto cache = fontconfig_caches + "/" + kCacheKey + "-le64.cache-11";
+ auto cache = fontconfig_caches + "/" + kCacheKey + "-le64.cache-9";
bool cache_exists = access(cache.c_str(), F_OK) == 0;
return !cache_exists;
}
--
2.50.1
|