Add the OS X code for fetching the default route.

Needs to be cleaned and and tested:
 - how are multiple entries handled?
 - what about non-default routes?
 - v4 vs v6
(cherry picked from commit a913b3088ba69c5362876768b14edded3638b0a3)
Clean up the GetDefaultRoute function for Mac.
(cherry picked from commit 2bfc04c9c00dc043787da293a127eb719e9d092a)
Fix a bug in the configure script
(cherry picked from commit b9ee6311535fc9bf4358cd93ccf15e24bb685812)