Latest changes for mac; Probably not portable