So i'll start of by saying she has mental illnesses, just to be clear that this is on-topic. She's fairly addicted to her pills, and has a lot of problems in general. She has this need to be someone's boyfriend or girlfriend, and without someone to tell her that they love them, she feels like trash. She is completely dependent on a significant other type of person. She's so desperate she's gone on tinder and has even slept with someone to try and get into a relationship.
Since i've broken up with her, she's slumped into this self-hating thought process where all she wants to do is pop pills, and occasionally mentions that she should down the whole bottle to commit suicide... she's not joking either. I've helped her through a lot of these episodes and problems, but they're just temporary. I can't count how many times i've convinced her not to kill herself, and to be clear, it's not fake she has attempted this before.
Her family does not care. If she tells them she's feeling suicidal, they laugh or tell her to shut up. From my brief time getting to know them, they're honestly probably the cause of her mental issues. They're also quite poor, sometimes they can't even pay for a meal all day because they need their paycheck first, so therapy for her isn't really an option. I'm the only thing keeping her sane.

.

How do I more permanently help her? How do I take away her need for a boyfriend without filling that gap myself?