This is really difficult.
I have compared Julisz's and Kean's patches.
Juliusz doesn't implement the -r option while Kean's code doesn't fix
the '(null)' problem, Kean doesn't generate an encodings file if no
encodings are to be processed while Juliusz generates one containing
a 0.
I could mix both fixes and we may get closer to the truth.

Kean Johnston writes:
 > Juliusz Chroboczek wrote:
 > > Please test
 > > 
 > >   http://bugs.xfree86.org/cgi-bin/bugzilla/show_bug.cgi?id=425
 > 
 > This fixes the -n -r problems for me, and compiles OK. However, are you 
 > trying to emulate the exact semantic behavious of mkfontdir? If so then 
 > the way you implement doEncodings is incorrect. In mkfontdir, it first 
 > does the unlink (removing the file) and then creates it if there are 
 > encodings to output. It does this regardless of whether or nor you 
 > specify -e. If there are no encodings there is no file, not a file with 
 > just a 0 (which is what will currently be produced). Its ordering is 
 > also different, which may or may not have an impact. The function that 

>From the code I don't see a difference in order between you version
and Juliusz's either, am I wrong?

 > produces encodings.dir is only run *after* the font tables are written, 
 > and only if that work didnt produce an error.

Yes, that's correct. Your fix however didn't change the order the
encodings and font tables are written either. This however should
be simple to do.

I will mix both patches together and will also do the order change.
I'll send the diff later so you guys can look at it and tell me
if its OK.

 > 
 > If these semantics are unimportant then ignore the above.
 > 
 > Please also note that the -x option conflicts with the usage in 
 > mkfontdir. In mkfontscale it means "add an encoding". In mkfontdir it 
 > means "ignore the following suffix". This is part of the reason why the 
 > fonts.dir file created during the build is a little more than double the 
 > size it needs to be, because -x isn't working. If the -x option is 
 > really entrenched in mkfontscale, then the mkfontdir wrapper is going to 
 > have to parse all arguments and convert a -x to some other option that 
 > does the same thing in mkfontscale. If you dont want to do that work let 
 > me know I'll happily add both the argument to mkfontscale and the mods 
 > to the mkfontdir script to cope with it. It would be much easier if we 
 > can just change the current -x option to be something else though.
 > 

This should definitely be fixed.

Egbert.
_______________________________________________
Devel mailing list
[EMAIL PROTECTED]
http://XFree86.Org/mailman/listinfo/devel

Reply via email to