This change accomplishes the following items:
1. Makes `libgtest` require pthread support.
2. Stops building static copies of the libraries.
3. Drops `gtest-config`.
4. Builds the upstream-provided tests.
== Makes `libgtest` require pthread support ==
As noted by @asomers in rS300906 (`cddl/usr.sbin/zfsd/tests/Makefile`
specifically), googletest requires libpthread in order to function, if
`-DGTEST_HAS_PTHREAD` is defined.
While this is true, the code was not being linked against libpthread,
resulting in libgtest being broken, and thus all tests reliant on the library
broken at runtime.
Long story short, the integration logic in `googletest/m4/acx_pthread.m4` is
broken. Switching to cmake unbreaks using googletest out of the box .
== Stops building static copies of the libraries ==
For whatever reason, the maintainers thought it was best to build either with
shared or static libraries, but not both. Switching to cmake makes this an
== Drops `gtest-config` ==
Using `gtest-config` when building from a GitHub clone results in incorrect
behavior, as it looks up the headers in `/usr/local/include` before the
headers in the local clone, making local builds with installed copies of
PR: 236169 
== Builds the upstream-provided tests ==
A number of tests are available with the gtest project. In order to do a
compare and contrast between the work I started as far as importing the
project to base, I needed to build/run them.