[Fontconfig] fc-cache is not always caching newly installed fonts.

Nguyen Vu Hung vuhung16plus at gmail.com
Wed Oct 24 03:10:21 PDT 2007


2007/10/24, Huang Peng <shawn.p.huang at gmail.com>:
> > > For b). fc-cache can not find new installed fonts too. :(
> > I guess it's the time-stamp on the files, although this seems odd. Is there no
> > way to locate/grep/touch through all fonts and update their timestamps? or
> > just set the time correctly and re-install the fonts.
>
> I can use 'fc-cahce -f' to re-create all caches. It's easy for me and
> most of Linux hackers.:) But it's difficult for ordinary desktop users.
> And I can not add 'fc-cache -f' in POST-INSTALL script of a font
> package, because it is too slow. Especially, when users install many
> font packages at the same time (like installing a OS, many font packages
> will be installed). It will invoke 'fc-cache -f' many times. It waste
> much time.
> That is the problem. Hope can find an acceptable solution.

FYI, Under a quite "fast" system, fc-cache -f takes 13 seconds with 155 fonts.

So if a Linux installer has to run that command one by one every time
a font is being installed, it will be a huge time.

Ref:
[root@ ~]# time fc-cache -f

real    0m13.280s
user    0m8.751s
sys     0m0.486s
[root@ ~]# fc-list | wc -l
155

[root@ ~]# cat /proc/cpuinfo  | grep model | grep name
model name      : Intel(R) Xeon(TM) CPU 3.20GHz
model name      : Intel(R) Xeon(TM) CPU 3.20GHz
[root@ ~]# cat /proc/cpuinfo  | grep processor | wc -l
2
[root@ ~]# cat /proc/meminfo  | grep MemTotal
MemTotal:      1034616 kB


-- 
Best Regards,
Nguyen Hung Vu
vuhung16plus{remove}@gmail.dot.com
An inquisitive look at Harajuku
http://www.flickr.com/photos/vuhung/sets/72157600109218238/


More information about the Fontconfig mailing list