Depends on the severity of the mental illness, and if its serious, whether they have help to raise the child(ren).
On the other hand, mrbiscoop has a good point. We require licenses to drive a car, but raising children, which is arguably the most important task one can take on, requires nothing more than a fertile pair of bodies.