Fixed  os detection
Added required dependencies for mac.