Can be totally fine
All depends on whether the child received adequate, consistent parenting
either by mom or others.
Having a mom who has mental illness is not the relevant question, and not the main issue that bear on likelihood of success in future relationships. There are many more people who end up having relationship difficulties and yet have perfectly healthy parents. Quality of parenting is more important.