1

I have been searching for a solution to this and I haven't found one. I have a tex file that uses metapost that compiles on one system but not on the other.

On the system that fails the log says:

Module luamplib Warning: This is MetaPost, Version 2.000
(luamplib)               
(luamplib)               
(luamplib)               
(luamplib)               ! I can't open file `plain.mp'.
(luamplib)               <*>     input plain.mp
(luamplib)                                      ;
(luamplib)               Please type another input file name
(luamplib)               ! Emergency stop.
(luamplib)               <*>     input plain.mp
(luamplib)                                      ;
(luamplib)               *** (job aborted, file error in nonstop mode)
(luamplib)               
(luamplib)               
(luamplib)               on input line 13
/usr/share/texlive/texmf-dist/tex/latex/base/ltluatex.lua:109: 
Module luamplib Error: see above messages on input line 13

But I am not including that mp file at all, I am including:

\RequirePackage{luatex85}
\documentclass[border=4cm]{standalone}

\usepackage{luamplib}
\mplibnumbersystem{double}
\usepackage[margin=0.5cm]{geometry}

\begin{document}
{\centering
\begin{mplibcode}
input metapost/lattice.mp;

\end{mplibcode}
\par}
\end{document}

And the file metapost/lattice.mp exists under the current relative path (checked). I am compiling with lualatex on TexStudio.

OS is Ubuntu. I tried updating packages and redownloading all tex related packages I remember using but alas problem is the same. enter image description here

3
  • 1
    plain.mp is necessary for luamplib. Try directly on your console lualatex filename.tex. If it succeeds, the problem may be a setting of TeXStudio. If it fails, your configuration is broken. Can kpsewhich plain.mp find the file plain.mp? May 14, 2020 at 7:23
  • Given the path in the error message above, you would expect to find plain.mp in /usr/share/texlive/texmf-dist/metapost/base/ -- if you can't find it, then I guess that you might need to install texlive-metapost, which is the package that provides it.
    – Thruston
    Jun 10, 2020 at 15:19
  • It has been months but, installing the package was the answer.
    – Makogan
    Dec 12, 2020 at 0:16

1 Answer 1

1

(Answering this as per comments)

Given the path in the error message above, you would expect to find plain.mp in /usr/share/texlive/texmf-dist/metapost/base/ -- since you can't find it, then apparently you need to install texlive-metapost, which is the package that provides it.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .