Why can't the community do the same thing you do personally?
Many (most?) of the homeless you see around you are your community. They don't need to be invited into the city because it's their home too.
I live in SF and I know homeless people who have lived on the same street corner longer than some of my coworkers have lived in the city (or even the country). Many of the people who experience such misfortunes - even drug addicts who behave poorly - are long-time residents who once helped make the city the place it is. Sure their behave causes issues, and society needs to do something, but implying they don't have a claim to be helped in their own city is unfair.
The second one. Over and over again. And when they are adults and we've given them a few more chances, we should then cut our losses. Many families go through the heartbreak which is trying again and again and failing. I don't judge those families, and know a few of those personally. And this is people's blood relatives. Extrapolate from that what you will.
Someone's claim to live in a good community ends when they start actively destroying that community day after day. You get the community you work to build; you don't get to live in my wonderful community every day while you daily do horrifying things to ruin it.
This is the only way good communities can exist.
Plus, productive citizens need to share a society with the drug addicted homeless. That society is going to be more peaceful if the needs of those homeless are met.