I have a clean install of texlive. While trying to compile any document which uses either the graphics, graphix, or the xcolor packages, I get errors that the compiler can't find the corresponding .def file.
pdftex.def - if I am using pdflatex
xetex.def - if I'm using xelatex
I have downloaded the graphics-def package from CTAN, and copied the .def
files to /texmf-dist/tex/latex/graphics
, but I had no luck. Maybe I don't know where the files are supposed to go.
The only thing that worked was putting the
.def
files in the same directory as my.tex
program.
This is surely a path error. Where do I put the def files so that the packages can find them?
EDIT: I'm using Windows and TeXStudio. (Although I'm getting the same errors when I compile via command line)
/etc/environment
file to add the path of TeXLive. Mine is/usr/local/texlive/2016/bin/x86_64-linux
. It's strange, though, that you could compile a file, given what you've just said..def
file is in the same directory asmyfile.tex
. So I assume I'm unable to locate the general path where the .def file should exist.C:\some-path\texlive\2016\texmf-dist\tex\latex\graphics-def
, as I don't really know the full path you installed TeXLive...\texlive\2015\texmf-dist\tex\latex\graphics-def
C:\texlive\2015
) in your PATH environment variable. See itechtics.com/customize-windows-environment-variables to know how to do so. Then, try to compile again and see if that works.