Re: incompatible changes in cache format

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Patrick Lam <plam@xxxxxxx> さんは書きました:

> Ideally we wouldn't change the cache format once fontconfig becomes
> stable.  But I guess that's not a very satisfactory answer, because we
> might have to change the cache format more than we might like.  One
> option is to increment the cache version number (fonts.cache-3, etc).
>
>> fcint.h contains a magic number
>> 
>>     #define FC_CACHE_MAGIC 0xFC02FC02
>> 
>> which appears to be intended for that purpose.
>
> The magic number just helps determine that it's a fontconfig cache, but
> I suppose it could be changed.  The other thing is that there's a line
> for determining architectures (by recording sizeof various things); this
> line could also have a version number incorporated into it.
>
> The question, I guess, is how often we're going to have these
> incompatible changes.  If it's not very often, then we increment the
> filename number.  If it's going to be more often than that, we can
> change the magic number.  I'm not really sure which is best.

Dirk Müller <dmueller@xxxxxxx> told me that incrementing the magic
number might cause a problem if some 3rd party software vendors
distribute applications which are statically linked against older
versions of fontconfig.

When calling such statically linked applications and "normal"
applications alternately, the cache files will always be updated
because the magic number is always wrong.

Dirk had the idea that this could be avoided by having a version
number in the architecture signature. You also wrote above that this
is a possibility.

Having the version number in the architecture signature might avoid
the problem with applications statically linked against fontconfig
because those would get their own architecture section.

I don't know whether applications linked statically against fontconfig
exist, i.e. I don't know whether this problem is important in practice
or not.

-- 
Mike FABIAN   <mfabian@xxxxxxx>   http://www.suse.de/~mfabian
睡眠不足はいい仕事の敵だ。

_______________________________________________
Fontconfig mailing list
Fontconfig@xxxxxxxxxxxxxxxxxxxxx
http://lists.freedesktop.org/mailman/listinfo/fontconfig

[Index of Archives]     [Fedora Fonts]     [Fedora Users]     [Fedora Cloud]     [Kernel]     [Fedora Packaging]     [Fedora Desktop]     [PAM]     [Gimp Graphics Editor]     [Yosemite News]

  Powered by Linux