Added flags for cross-platform building
Made the SHA1 hash stuff compile cleanly on OSX and Linux