Backport osx64 support to 2.6