Suppose you have old PostScript or Encapsulated PostScript files around and wish to convert them to more modern PDF documents. You have a variety of options for this:

  • macOS has Preview.app which converts (E)PS documents to PDF on the fly upon double-clicking and its command-line conversion companion pstopdf. However these tools fail sometimes when it comes to embedded fonts or the correct BoundingBox.
  • MacTeX brings the epspdftk utility (my personal favorite), a Windowing Shell script for converting between PDF, EPS, and PS, as well as a bunch of command-line utilities like the epspdf epstopdf programs.
  • GhostScript, installed for example by MacTeX in standard installation mode, comes with the general-purpose command gs and utility scripts around it. One example is the ps2pdf command which however like gs by default boldly sets the resulting BoundingBox to the paper size configured for gs. To force ps2pdf to preserve the original BoundingBox, run the utility with the -dEPSCrop option, for example "ps2pdf -dEPSCrop fig7.eps" will generate fig7.pdf with the correct BoundingBox.