Just a thought, but maybe a social safety net would be more effective in preventing the homeless from getting into the kind of state where they do that? Rather than more security. Just thinking laterally about the problem here..
We can do both at the same time. We can help the homeless and also prevent people from shitting or littering in public transportation vehicles and on boarding platforms.