kpathsea: Unable to generate fonts
8.5.3 Unable to generate fonts
------------------------------
Metafont outputs fonts in bitmap format, tuned for a particular device
at a particular resolution, in order to allow for the highest-possible
quality of output. Some DVI-to-whatever programs, such as Dvips, try to
generate these on the fly when they are needed, but this generation may
fail in several cases.
If 'mktexpk' runs, but fails with this error:
mktexpk: Can't guess mode for NNN dpi devices.
mktexpk: Use a config file to specify the mode, or update me.
you need to ensure the resolution and mode match; just specifying the
resolution, as in '-D 360', is not enough.
You can specify the mode name with the '-mode' option on the Dvips
command line, or in a Dvips configuration file (⇒(dvips)Config
files), such as 'config.ps' in your document directory, '~/.dvipsrc'
in your home directory, or in a system directory (again named
'config.ps'). (Other drivers use other files, naturally.)
For example, if you need 360dpi fonts, you could include this in a
configuration file:
D 360
M lqmed
If Metafont runs, but generates fonts at the wrong resolution or for
the wrong device, most likely 'mktexpk''s built-in guess for the mode is
wrong, and you should override it as above.
See <https://ctan.org/pkg/modes> for a list of resolutions and mode
names for most devices (additional submissions are welcome).
If Metafont runs but generates fonts at a resolution of 2602dpi (and
prints out the name of each character as well as just a character
number, and maybe tries to display the characters), then your Metafont
base file probably hasn't been made properly. (It's using the default
'proof' mode, instead of an actual device mode.) To make a proper
'plain.base', assuming the local mode definitions are contained in a
file 'modes.mf', run the following command (assuming Unix):
inimf "plain; input modes; dump"
Then copy the 'plain.base' file from the current directory to where the
base files are stored on your system ('/usr/local/share/texmf/web2c' by
default), and make a link (either hard or soft) from 'plain.base' to
'mf.base' in that directory. ⇒(web2c)inimf invocation.
If 'mf' is a command not found at all by 'mktexpk', then you need to
install Metafont (⇒unixtex.ftp).