CMakeLists.txt: Fix a concurrency issue

Due to a limitation in CMake, all of the top level targets are executed
concurrently, which results in multiple simultaneous attempts to build
the main library. Removing the main library as a top-level target seems
to fix the issue, while still building the library as a dependency of
the other top-level targets.

See http://public.kitware.com/Bug/view.php?id=10082 for more
information.