Stop linking pthread.

It was only needed by gtest, which is no longer used.
(Intesting note: I checked when the -lpthread flag was added, and it's
been around since the first revision of build.ninja, which used to be
checked in before configure.py existed. Back then, it looks like '@' was
used to dereference built-in variables, and build outputs were also
prefixed by '@'!).
Remove now-unused variable test_libs.
Merge pull request #863 from nico/nopthread

Stop linking pthread.