LyXProblems with pdfpages and relative paths

Information and discussion about LyX, a WYSIWYM editor, available for Linux, Windows and Mac OS X systems.
Post Reply
hausi
Posts: 1
Joined: Sun Oct 26, 2008 4:15 pm

Problems with pdfpages and relative paths

Post by hausi »

Hi

We have to include some pdf files and are trying to use pdfpages to achieve this. Because LyX does not yet support this, we use ERT to include the pdf (upgrading to 1.6, which seems to support it is currently not an option).
LyX uses a temporary directory for exporting a pdf file to not clutter the user directory. When it does that, it copies all needed files to this directory and sets input@path to the original path.

Now to the problem: As it seems, pdfpages does not care about input@path, but uses Ginput@path instead. What LyX generates for me (without the useless stuff) is:

Code: Select all

\batchmode
\makeatletter
\def\input@path{{/old/path/to/document/}}
\makeatother

\documentclass{report}
\usepackage{pdfpages}

\begin{document}
\includepdf[pages=1]{pdfpages.pdf}
\end{document}
I can't just use \makeatletter \input@path, because it has an additional {} in it and thus won't find the path.
I can't just let pdfpages handle it, because this only seems to work, when I rename the def to Ginput@path manually.
I can't use absolute paths, because there are many people working on this document using different setups and platforms.
I couldn't figure how to define Ginput@path in a way that pdfpages handles it correctly.

Any pointer in the correct direction would be very helpful and finally put an end to my two days of searching for a solution.

Recommended reading 2024:

LaTeXguide.org • LaTeX-Cookbook.net • TikZ.org

NEW: TikZ book now 40% off at Amazon.com for a short time.

User avatar
Maksi
Posts: 52
Joined: Sun Mar 16, 2008 12:12 pm

Problems with pdfpages and relative paths

Post by Maksi »

Sorry, I can only help you by recommending you posting to the LyX developers mailing list. I understand your problem but have no idea how to solve it. However, the LyX developers are very friendly and helpful :)
A Humanities user of LaTeX :)
Post Reply