added initial support for mac