Comprehensive line lists for phosphorus monoxide ($^{31}$P$^{16}$O) and phosphorus monosulphide ($^{31}$P$^{32}$S) in their $X$ $^2Pi$ electronic ground state are presented. The line lists are based on new ab initio potential energy (PEC), spin-orbit (SOC) and dipole moment (DMC) curves computed using the MRCI+Q-r method with aug-cc-pwCV5Z and aug-cc-pV5Z basis sets. The nuclear motion equations (i.e. the rovibronic Schrodinger equations for each molecule) are solved using the program Duo. The PECs and SOCs are refined in least-squares fits to available experimental data. Partition functions, $Q(T)$, are computed up to $T=$ 5000 K, the range of validity of the line lists. These line lists are the most comprehensive available for either molecule. The characteristically sharp peak of the $Q$-branches from the spin-orbit split components give useful diagnostics for both PO and PS in spectra at infrared wavelengths. These line lists should prove useful for analysing observations and setting up models of environments such as brown dwarfs, low-mass stars, O-rich circumstellar regions and potentially for exoplanetary retrievals. Since PS is yet to be detected in space, the role of the two lowest excited electronic states ($a$ $^4Pi$ and $B$ $^2Pi$) are also considered. An approximate line list for the PS $X - B$ electronic transition, which predicts a number of sharp vibrational bands in the near ultraviolet, is also presented. he line lists are available from the CDS (cdsarc.u-strasbg.fr) and ExoMol (www.exomol.com) databases.