[metapost] verbatimtex bug?

Dan Luecking luecking at uark.edu
Thu Oct 29 04:32:05 CET 2009

The following test file fails:

% test.mp
label(btex \viiipt X etex,(0,0);
end % end of test.mp

The screen error message is:

This is MetaPost, version 1.208 (kpathsea version 5.0.0)
(./test.mpkpathsea: Invalid fontname `cmr8{}', contains '{'
fatal: Command failed: etex --parse-first-line 
--interaction=nonstopmode mpa00536.tex; see mpxer
 >> test.mp
 >> test.mpx
! Unable to make mpx file.
l.9 label(btex
                \viiipt X etex,(0,0);
Transcript written on test.log.

I am using TeX Live 2009 but I get the same result in TeX Live 2008
(mpost version 1.005).

The error seems to come from the following output of mpto -tex. Note the
"%" right after cmr8, which causes TeX to continue reading the tfm name
until line 3, and thinks the font name is "cmr8{}":

% line 5 test.mp
\gdef\stopmpxshipout{\egroup  \dimen0=\ht0 \advance\dimen0\dp0
   \dimen1=\ht0 \dimen2=\dp0
     \ifnum\dimen0>0 \vrule width1sp height\dimen1 depth\dimen2
     \else \vrule width1sp height1sp depth0sp\relax
   \ht0=0pt \dp0=0pt \box0 \egroup}
\mpxshipout% line 9 test.mp
\viiipt X%

It seems to me that verbatimtex ought to be verbatim and line
ends ought not be commented out.

Note: I had to use TeX Live 2008's mpto.exe. It would certainly
help with debugging if the facilities of mpto were available with
the current metapost.


Daniel H. Luecking
Department of Mathematical Sciences
University of Arkansas
Fayetteville, AR 72701 

More information about the metapost mailing list