Reopening: Q: webfonts:

Petr Vobornik pvoborni at redhat.com
Mon Dec 2 15:33:56 UTC 2013


On 11/30/2013 09:04 PM, Paul Flo Williams wrote:
> Petr Vobornik wrote:
>>> Nicolas Mailhot wrote:
>>>>
>>>> Just write a fontforge or ttx script that flips this bit at rpm build
>>>> time, assuming you've done your legal review correctly the bit is in
>>>> contradiction with the font license (if the font was no installable we
>>>> could not package it in the first place). You'll be doing nothing more
>>>> than fixing a bug in upstream's font implementation.
>>
>> OK, seems to be the easiest way. Originally, I wanted to avoid it
>> because idk what is the correct way. I've created a simple script to do
>> it:
>>
>> [snip]
>>
>> The script is not good because it doesn't touch only OS/2 table but it
>> regenerates the whole font file (different GPOS, dropping DSIG and
>> without fmflags also dropping KERN table).
>>
>> I've also tried to use ttx with a hope that it won't touch other tables,
>> but it crashed on parsing OpenSans font.
>
> Considering changing fsType is just a change to 16 bits + a 32-bit
> checksum, it shouldn't be necessary to regenerate the entire font. In
> fact, Tom7 created a program to do just this job many years ago, called
> "embed":
>
> http://carnage-melon.tom7.org/embed/
>
> I've just improved this to recalculate the OS/2 table checksum correctly
> and handle multiple fonts in one go:
>
> https://github.com/hisdeedsaredust/ttembed
>
> If you'd like to package this as well, you could use it in your Open Sans
> package and you'd have something else to show sponsors :-)
>

This solution is much nicer and can be used by other font packages as well.

Here's the new package: https://bugzilla.redhat.com/show_bug.cgi?id=1036754
-- 
Petr Vobornik


More information about the devel mailing list