[lltx] behaviour of luaotfload

Khaled Hosny khaledhosny at eglug.org
Tue May 18 17:01:25 CEST 2010


On Tue, May 18, 2010 at 03:41:28PM +0300, Elie Roux wrote:
> Hello,
> 
> with the current master of luaotfload, I get an error
> 
> !LuaTeX error: cannot find OpenType font file for reading
> ==> Fatal error occurred, no output PDF file produced!

This means the pdf backend can't find the font we passed to it, this
used to happen with outdated names database, i.e. we are passing to it a
font that doesn't exist or can't be found by kpse. May be you generated
your database with OSFONTDIR set and then run luatex with it unset?
This shouldn't be an issue actually, as luaotfload will update the
database in such case. 

> at the end of the compilation... does someone know where it comes
> from? It appears if a font is in the TEXMFHOME directory and is
> called with \font directly (with or without file: at the beginning).
> Do other people have this problem? Also, the current method doesn't
> work with font in the current directory, which is a quite strong
> regression. I'll try to fix it, but it's not that simple, as I
> didn't write anything in names.resolve(); Khaled, could you take a
> look?

Well, the code is getting too hacky, I guess I need to set down rewrite
it with all these issues in mind not as an afterthought.

> Also, the behaviour seems strange in very simple cases: if I do
> \font\test=fxlri.otf, it will try to look for the name, and if won't
> find it, so it will regenerate the database and try again. Wouldn't
> it be better to look if we find a font file extention to the name,
> and then simply return instead of regenerating the database?

Instead of adding yet another hack, people should just use the already
documented syntax for loading fonts by filename:

\font\foo=file:foo.bar

One already knows he is using a luaotfload specific feature when he
trays load font files with extensions.

Regards,
 Khaled

-- 
 Khaled Hosny
 Arabic localiser and member of Arabeyes.org team
 Free font developer


More information about the lualatex-dev mailing list