But how?
Jail or prison for whatever legal violations they make would be very expensive for taxpayers.
Putting them in supervised housing (as mentioned upthread) may cost significantly less than jail or prison, but there will be political resentment at providing free housing and services for those commonly seen as undeserving of anything, so that such programs will be targeted for cuts whenever governments have budget problems.