Compile with clang's libc++

An overload for std::swap() what works with std::pair<A,B> is included
in libc++ (but not libstdc++). Avoid ambiguity in HashTable.h by
omitting the version there and using the std::swap() version.

Collector.cpp needs to include pthread.h directly, as it is not
automatically included by libc++'s headers (libstdc++ does pull in
pthread.h though).

Cherry-picked from qtscript/48baeef0766ba145d26d374561e152b40245f3b8.

Change-Id: I4dc88638ce8553bb97037b841fc6cc5e8c9911e2
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>