Fixing Mac OS building issues