attempt to fix osx-10.9

hey, I have osx 10.9 and I needed to do some of these changes to get it working.

some of the tests don't pass, but this is an osx 10.9 only issue... I don't really know what's going wrong, but for photo cropping and resizing it works perfectly