Clang fixes

On Mavericks using clang/clang++ and Mountain Lion using gcc/g++ or clang/clang++ this successfully builds all tests for csharp,  java, go, php, perl, python, ruby, and tcl.  Also ran tests for D - fixed clang issues, other errors I observed were same for this branch and master.

To build using clang I ran configure like
     ./configure.sh --prefix=/some/dir 'CC=clang' 'CXX=clang++' 'CXXFLAGS=-stdlib=libc++'

[Edit: initially, CXXFLAGS was being set like this.  The patch has evolved, and CXXFLAGS is no longer set explicitly.  Instead, configure.ac has been updated to add it to PLATCXXFLAGS which only affects building tests and example code]

I also had to first build a local version of mono, since need a 64 bit version of mono to run the csharp tests.
I used mono 3.2.3, configured like
     ./configure.sh --prefix=/some/dir --with-glib=embedded --enable-nls=no --host=x86_64-apple-darwin10
I also had to fix-up references to ./install-sh in Makefiles to make the paths absolute, for some reason.