Support for MacOS X (Rhapsody) is added. Also get rid of volatile