readlink on OS X is not the same as readlink on Linux

I was getting errors loading the plugin because OS X's readlink
isn't at all like readlink on Linux.