Additional binary checks and sytanx error fixes.

- Check for bc binary
- Linux syntax corrections
- Change to bash script