Changes for use under MacOS