more work to get this to compile on OS X and newer versions of libtool