Error using epstopdf package

I am currently using pdflatex on my Mac OS Yosemite to compile a simple code which is to demonstrate the problem I am having with another larger file. I am using TexLive 2014 and when running the following code on TexStudio I get an error:

\documentclass[11pt,notitlepage]{article}
\usepackage[utf8]{inputenc}
\usepackage[margin=0.5in]{geometry}
\usepackage{graphicx}
\usepackage{epstopdf}

\begin{document}
\includegraphics{test.eps}
\end{document}


I have tried every combination of including the .eps extension, or removing the \usepackage{epstopdf}, or placing \epstopdfsetup{outdir=./}. I don't know what I could possibly be doing wrong. I have also tried compiling using TexMaker and TexShop, but nothing works. The error I get in my log is the following:

(/usr/local/texlive/2014/texmf-dist/tex/context/base/supp-pdf.mkii
[Loading MPS to PDF converter (version 2006.09.02).]
\scratchcounter=\count91
\scratchdimen=\dimen113
\scratchbox=\box26
\nofMPsegments=\count92
\nofMParguments=\count93
\everyMPshowfont=\toks18
\MPscratchCnt=\count94
\MPscratchDim=\dimen114
\MPnumerator=\count95
\makeMPintoPDFobject=\count96
\everyMPtoPDFconversion=\toks19
)
Package epstopdf Info: Source file: <test.eps>
(epstopdf)                    date: 2014-08-01 13:34:15
(epstopdf)                    size: 6154549 bytes
(epstopdf)             Output file: <test-eps-converted-to.pdf>
(epstopdf)             Command: <repstopdf --outfile=test-eps-converted-to.pdf
test.eps>
(epstopdf)             \includegraphics on input line 8.
runsystem(repstopdf --outfile=test-eps-converted-to.pdf test.eps)...executed sa
fely (allowed).

Package epstopdf Info: Result file: <test-eps-converted-to.pdf>.

! Package pdftex.def Error: File test-eps-converted-to.pdf' not found.

See the pdftex.def package documentation for explanation.
Type  H <return>  for immediate help.
...

l.8     \includegraphics{test}

Using draft setting for this image.
Try typing  <return>  to proceed.
If that doesn't work, type  X <return>  to quit.

[1

{/usr/local/texlive/2014/texmf-var/fonts/map/pdftex/updmap/pdftex.map}] (./docu
ment.aux) )


Thank you so much in advance to anyone who can help!

• Are you using the option --shell-escape within pdflatex? – Sigur Oct 18 '14 at 2:37
• Yes, I have tried using that. – MCF57 Oct 18 '14 at 2:43
• Can you upload the file test.eps somewhere and add a link to your question? Also, what happens if you do the conversion manually (i.e. epstopdf test.eps in the terminal)? Do you get a usable pdf image? – Ian Thompson Oct 18 '14 at 9:57
• Ian, thank you so much for your help. When running epstopdf manually as you suggested while cd'ing to the folder containing the image I get the following error. 'dyld: Library not loaded: /usr/X11/lib/libXt.6.dylib Referenced from: /usr/local/bin/gs Reason: image not found' – MCF57 Oct 19 '14 at 22:12
• To add to that, I think there may also be a contribution to this issue when I updated my X11 to XQuartz 2.7.7. Also in regards to the eps image you can find it at goo.gl/nlQb6j – MCF57 Oct 19 '14 at 22:28

So here's where we ended up (see edits and comments for the history):

User recently upgraded to OS X 10.10 (Yosemite), and couldn't automatically convert any EPS graphics into PDF as he'd done previously.

The user was also unable to use the known-working (but probably not truly minimal) MWE of

\documentclass[11pt,notitlepage]{article}
\usepackage[utf8]{inputenc}
\usepackage[margin=0.5in]{geometry}
\usepackage{graphicx}

\begin{document}
%\includegraphics{207754.eps}
% copied from /usr/local/texlive/2014/texmf-dist/tex/latex/mwe/example-image-a.eps
\includegraphics{207754-op.eps}
\end{document}


The same graphics and the same documents converted correctly on a Windows 7 system, and on other Yosemite systems.

The user was unable to use the epstopdf shell command to convert the graphics as well. This gave an error of dyld: Library not loaded: /usr/X11/lib/libXt.6.dylib Referenced from: /usr/local/bin/gs Reason: image not found.

The user had installed XQuartz at some point before the Yosemite upgrade.

In the end, it appears that the OS X upgrade undid some of the work of the XQuartz application, similar to how it undoes some of the work of the MacTeX installer, requiring the use of the FixMacTeX2014.pkg or similar packages. The image not found error also shows up in other X11-related applications after OS upgrades, such as wireshark. Since GhostScript is the main executable at the core of epstopdf command and the automatic conversion of EPS graphics to PDF in the newer graphicx packages, its failure to run was the root cause.

Reinstalling XQuartz (or possibly just restoring the symbolic link from /usr/X11 to /opt/X11) after the Yosemite upgrade fixed the problem.

• Mike, thanks for the information. As I mentioned, I tried every possible combination of including and not including the 'epstopdf' but nothing seems to work. This problem happens to all of my EPS figures, as it is my choice of figure formatting given the high resolution from its vectorized format. All was working well and compiling before I updated my Mac to OS Yosemite a couple of days ago. However the example image I am trying to include on my document be found at goo.gl/nlQb6j – MCF57 Oct 19 '14 at 22:22
• I'll grab that image shortly. In the meantime, does my MWE work on your system? Mine's also Yosemite and MacTeX 2014. If my document works as is, then try your image in my document. That should narrow it down to either your image or your TeX installation. – Mike Renfro Oct 19 '14 at 22:25
• Your image worked for me. So it doesn't appear to be the image. I assume that (for some unknown reason) you won't be able to build with the image from the MWE package. In your other conversation, one difference between our systems is that I've never installed XQuartz on this system at all. – Mike Renfro Oct 19 '14 at 22:40
• Reinstalling XQuartz from xquartz.macosforge.org/landing solved this problem for me. – Seamus O'Bairead Nov 17 '14 at 10:35

This is the quickest solution:

The upgrade moves /usr/X11 to /opt/X11 which is interesting as a fresh install of Yosemite already has it's own /usr/X11. However to fix it, in Terminal, I did:

 sudo ln -s /opt/X11 /usr/X11
sudo ln -s /opt/X11 /usr/X11R6
`
• Simple and worked. It is a short version of the previous answer, I know. – fiacobelli Mar 4 '15 at 18:24