I want to include a multipage-pdf in latex and get .dvi output. I know \include{pdfpages} only works with pdfLaTeX. I can't convert PDF to .eps since it is multi-page. I want to have .dvi output with a PDF included. Any way to do that?

  • 1
    Why do you need .dvi output? Why not split the PDF into separate pages and convert each to .eps format? – Joseph Wright Aug 4 '12 at 21:49
  • I have the same question. I want to embed a the PDF output of a Latex document into another one (with the ability to select the range of pages to be included). Using PDFLatex compiler, it is easy using the 'pdfpages' package. However, now I need to do it with Latex compiler for a document. – imriss Dec 17 '13 at 14:14

You can convert the PDF file to EPS files. Either you select page by page or depending on the converter this can be done in one conversion pass.

pdftops (from xpdf) knows the following options that are useful here:

  • -f <int> specifies the first page
  • -l <int> specifies the last page
  • -eps converts to EPS

Command line for the second page of test.pdf written to test02.eps:

pdftops -eps -f 2 -l 2 test.pdf test02.eps

ghostscript can select pages and write to multiple output files. Example from above:

gs -dBATCH -dNOPAUSE -sDEVICE=epswrite -sOutputFile=test%02d.eps

This writes files test01.eps, test02.eps, and test03.eps. %02d means, the page number with at least two digits are written with a leading zero if necessary (numbers < 10).

Also single pages can selected with ghostscript:

gs -dBATCH -dNOPAUSE -sDEVICE=epswrite -dFirstPage=2 -dLastPage=2 -sOutputFile=test02.eps test.pdf

Also -sOutputFile=test%02d.eps can be used here, %02d will be replaced by the page number 02.

Your Answer

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

Not the answer you're looking for? Browse other questions tagged or ask your own question.