Make bin/setup portable

I assume portability is a goal here, but the use of UNIX utilities and direct invocation of a binstub make this a nonstarter on Windows. There is also a minor issue that `rm -f log/*.log` will cause an error on csh when no log files are present.

FileUtils seems like the ideal approach.