Heavy-quark spectroscopy on the lattice