This program is part of Netpbm.
ppmtojpeg was replaced in Netpbm 9.19 (September 2001) by pnmtojpeg.
pnmtojpeg is backward compatible with ppmtojpeg except that with PGM or PBM input, it generates JPEG output in the special grayscale format.