Build fixes and clock_get_time copy from paul querna

Reviewed By: mcslee


git-svn-id: https://svn.apache.org/repos/asf/incubator/thrift/trunk@665085 13f79535-47bb-0310-9956-ffa450edef68
diff --git a/lib/cpp/bootstrap.sh b/lib/cpp/bootstrap.sh
index 34df69d..431e35a 100755
--- a/lib/cpp/bootstrap.sh
+++ b/lib/cpp/bootstrap.sh
@@ -4,7 +4,11 @@
 autoscan
 autoheader
 aclocal -I ./aclocal
-libtoolize --automake
+if glibtoolize --version 1 >/dev/null 2>/dev/null; then
+  libtoolize --automake
+elif glibtoolize --version 1 >/dev/null 2>/dev/null; then
+  glibtoolize --automake
+fi
 touch NEWS README AUTHORS ChangeLog
 autoconf
 automake -ac