BSD / Mac compability

changed shell script to work on Mac / BSD, added Mac specific DEPENDENCIES using brew