Tested on OS X an Linux.