[libc++] Towards a simpler extern template story in libc++
The flexibility around extern template instantiation declarations in
libc++ result in a very complicated model, especially when support for
slightly different configurations (like the debug mode or assertions
in the dylib) are taken into account. That results in unexpected bugs
like http://llvm.org/PR50534 (and there have been multiple similar
bugs in the past, notably around the debug mode).
This patch gets rid of the _LIBCPP_DISABLE_EXTERN_TEMPLATE knob, which
I don't think is fundamental. Indeed, the motivation for that knob was to
avoid taking a dependency on the library, however that can be done better
by linking against the static library instead. And in fact, some parts of
the headers will always depend on things defined in the library, which
defeats the original goal of _LIBCPP_DISABLE_EXTERN_TEMPLATE.
Differential Revision: https://reviews.llvm.org/D103960
NOKEYCHECK=True
GitOrigin-RevId: 2ae52326dab0a771b6167bc61a858389ac609ccc
diff --git a/docs/ReleaseNotes.rst b/docs/ReleaseNotes.rst
index cb4691f..2042b35 100644
--- a/docs/ReleaseNotes.rst
+++ b/docs/ReleaseNotes.rst
@@ -120,6 +120,11 @@
the library has been built with support for the debug mode, and it will be
enabled automatically (no need to define ``_LIBCPP_DEBUG``).
+- The ``_LIBCPP_DISABLE_EXTERN_TEMPLATE`` macro is not honored anymore when defined by
+ users of libc++. Instead, users not wishing to take a dependency on libc++ should link
+ against the static version of libc++, which will result in no dependency being
+ taken against the shared library.
+
ABI Changes
-----------