https://github.com/bazelbuild/bazel/issues/7362
This PR updates `cc_library`s to use `alwayslink=1` when needed. Currently, library archives and library object groups are wrapped in `--whole_archive`, `--no_whole_archive`, thus the whole library is always linked. This changes with Bazel 1.0, and libraries that export otherwise unused symbols must be tagged as `alwayslink=1`.
This PR fixes https://github.com/tensorflow/tensorflow/issues/32835 (once again, as it was fixed by https://github.com/tensorflow/tensorflow/pull/33415 but the codebase regressed in the meantime.)
It also fixes most of the TF tests.
PiperOrigin-RevId: 276772147
Change-Id: I05db02e84200a484df52f4f02b601dc486636912