From the Apple docs,
Open Print Center, choose Add Printer from the Printers menu, and choose "LPR Printers using IP" (or "IP printing") from the pop-up menu. Type "localhost" (no quotation marks) in the LPR Printer's Address field, choose a printer from the Printer Model pop-up menu, and click Add.
To save a PostScript file, choose the printer named "localhost" in the Print dialog and set the Output Options to save a PostScript file.
To give the printer a better name, deselect "Use Default Queue on Server" and type a name in the Queue Name field when you add the printer. Leave the address as "localhost."