After installing TeX Live 2012 in a non system directory (not sure if this makes a difference) and running some of the tests found at TeX Live Install, LuaTeX can't find the example font metrics even though xetex can.

$ luatex opentype-info.tex 
This is LuaTeX, Version beta-0.70.2-2012062812 (TeX Live 2012)
 restricted \write18 enabled.
! Font \testfont=Latin Modern Roman/ICU at 12pt not loadable: metric data not found or bad.
<to be read again> 

? X
No pages of output.
Transcript written on opentype-info.log.
$ xetex opentype-info.tex 
This is XeTeX, Version 3.1415926-2.4-0.9998 (TeX Live 2012)
 restricted \write18 enabled.
entering extended mode
(./opentype-info.tex [1] )
Output written on opentype-info.pdf (1 page).
Transcript written on opentype-info.log.

How can I fix my LuaTeX install?

  • You have at least to \input luaotfload.sty, but then the compilation fails at \XeTeXOTcountscripts
    – egreg
    Apr 29 '13 at 23:42
  • 2
    Related/duplicate: tex.stackexchange.com/questions/105869/…
    – egreg
    Apr 29 '13 at 23:44
  • So this means the Testing the Installation comment (Or the same for luatex.) is wrong or is there additional post-install configuration that is necessary?
    – rickhg12hs
    Apr 30 '13 at 1:10
  • 3
    opentype-info.tex is a XeTeX specific file, so the errors are expected. The documentation is at fault here. Apr 30 '13 at 1:24
  • Thanks! Maybe an answer should point out the fault (or ambiguity) of the TeX Live 2012 post-install tests and perhaps suggest another file to use for LuaTeX tests. It's disconcerting for newbies when post-install tests fail.
    – rickhg12hs
    Apr 30 '13 at 1:30

The Web page you refer (Testing the installation) is indeed not very informative about LuaTeX.

It's not really possible to test fonts with opentype-info.tex by two reasons:

  1. the file doesn't enable the font loading mechanism for LuaTeX;
  2. it has specific XeTeX commands that LuaTeX can't understand.

A small test file might be

\def\myfontname{Latin Modern Roman} % <- change here

\input luaotfload.sty

\font\testfont="\myfontname" at 12pt

Some text: the quick brown fox jumps over the lazy dog

  • 1
    @egreg Playing with the fontsize, I also found that I needed to add \testfont before the text. I wonder what the default font is.
    – rickhg12hs
    Apr 30 '13 at 18:27
  • 1
    @rickhg12hs by default luatex loads the same Computer Modern fonts as pdftex (tfm, not otf). Apr 30 '13 at 20:48
  • 1
    @rickhg12hs You're again right
    – egreg
    Apr 30 '13 at 21:00

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.