Pax is used to restore URLs inside PDFs that are embedded with \includegraphics. First, for every included PDF you create a .pax file, which sits in the same directory as the figure it is related to. Then, you simply add \usepackage{pax} to .tex and compile your project. All works great.

However, if the default graphics path has been changed, pax no longer sees its auxiliary files and fails to fix metadata in the resulting PDF.

Here is an example:


This works:


This does not (the links inside included PDFs disappear):


If I put diagram.pax into the project’s root directory, the second example starts functioning. This workaround is fine if you don’t mind your root directory to be cluttered, however, it can’t be applied in absolutely all cases. For example, if my latex project consists of chapters, and I want dependencies to go into deps/a/, deps/b/, etc., I might end up having two pax files with the same name and won’t be able to keep them all in the root directory.

I assume this issue should be handled by pax developers, but what if there is still an easy solution someone in my situation could use?

Any suggestions?

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.