# [metapost] macro path

nicola vitacolo at dimi.uniud.it
Mon Mar 26 14:13:03 CEST 2007

In article
"Mojca Miklavec" <mojca.miklavec.lists at gmail.com> wrote:

> On 3/25/07, Steve MC Han wrote:
> > Hi,  I have trouble with metapost. Could someone give some insight for this?
> >
> > This is the error message.
> >
> > <<! Unable to make mpx file.
> > l.78 label.bot(btex
> >                     $\hbox{\sf Rectangle}$ etex, (0,-.6u));
> > 6 output files written: 2MS4.1 .. 2MS4.8
> > Transcript written on 2MS4.log.>>
> >
> > So, I tried set the path straight by typing "c:\TexLive2007\bin\win32" at
> > command prompt, it magically worked. But with different file, I still have
> > trouble with similar error message. This time, even with set path like
> > above, it didn't work.
> >
> > <<mpost --tex=latex 2MS3
> > This is MetaPost, Version 0.993 (Web2C 7.5.6)
> > (2MS3.mp [0] [1] [2] [3] [4] [5] [6] [7] [8] [9] [10]makempx: Command
> > failed: la
> > tex mpxerr.tex; see mpxerr.log
> > >> 2MS3.mp
> > >> 2MS3.mpx
> > ! Unable to make mpx file.
> > l.156 label.lft(btex
> >                      $A$ etex, z8);
> > 11 output files written: 2MS3.0 .. 2MS3.10
> > Transcript written on 2MS3.log.>>
> >
> > This trouble started after I did "mptopdf". At first, mptopdf didn't create
> > pdf files even thoufgh there was no error message. So, by consulting Contex
> > conversion to pdf manual
> >
> > http://tex.aanhet.net/context/mirror/general/sources/mptopdf.pdf
> >
> > I typed "pdftex --ini mptopdf" at prompt command and after that it produced
> > pdf files but now mpost didn't work with the above error message. I think
> > path
> >
> > c:/TeXLive2007/texmf-var/fonts/map/dvips/updmap/psfonts.map
> >
> > is screwed up somehow.
>
> The mechanism has been changed heavily in May 2006 (before that, the
> old mechanism sometimes didn't recognize ConTeXt properly), so I was
> finally glad that it worked as it should. But no LaTeX user has ever
> upgraded ConTeXt before TeXLive 2007 came around. I used mptopdf, but
> it never came to my mind to try it with the latex switch.
>
> In the long term it should really be fixed, but as a temporary
> workaround you should be able to convert files without the latex
> switch. If you need some special settings (a special font or whatever
> else), please post some concrete example. You can just delete
> everything latex-related and safely use ConTeXt command with mptopdf
> (which really shouldn't be much different).
>
> I'm really sorry for the inconvenience ...
>
>
> Mojca
>
>
> A minimal example for Hans:
>
> verbatimtex
> %&latex
> \documentclass[12pt,a4paper]{article}
> \begin{document}
> etex
>
> beginfig(1);
>   draw btex $A$ etex;
> endfig;
> end.
>
> (perhaps it would make sense to add a note on
> http://www.tug.org/texlive/bugs.html)

Just to mention that last weekend I have posted a similar problem in
gmane.comp.tex.context (maybe this mailing list is better for questions
related to mptopdf?):

>From what I have read above, I deduce that mptopdf should not be used
with %&latex (at least for now), but I would be glad if someone could
answer the questions of my other message, because I am a bit confused
(after all, mptopdf does call mpost, right?).

One reason why I would use mptopdf with LaTeX is to include images with
externalfigure and to add labels with LaTeX-specific features (e.g.,
symbols in mathrsfs or yfonts packages). Is there a better way to do
that?

Nicola