Skip to content
This repository was archived by the owner on Feb 25, 2025. It is now read-only.

Commit f4b43b5

Browse files
committed
Opt into unstable libcxx ABI and add a custom namespace.
We use a statically linked libcxx and don't expose any of the internal symbols. This theoretically allows us to namespace everything to avoid accidentally using the wrong version libcxx. Also, not having to worry about ABI stability allows libcxx to opt into optimized routines. But, since libcxx uses CMake and we don't, the mechanism to generate the __config_site file doesn't exist in GN. Instead, we check in a file that would have been generated for us by CMake. The file we check in though is a default with additional configuration. This version of the file makes it so that we opt into the unstable ABI (and get optimizations) and also namespace everything for Flutter so collisions are immediately flagged.
1 parent a1777a3 commit f4b43b5

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

build/secondary/third_party/libcxx/config/__config_site

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,9 @@
11
#ifndef _LIBCPP_CONFIG_SITE
22
#define _LIBCPP_CONFIG_SITE
33

4-
/* #undef _LIBCPP_ABI_VERSION */
5-
/* #undef _LIBCPP_ABI_UNSTABLE */
4+
#define _LIBCPP_ABI_VERSION 2
5+
#define _LIBCPP_ABI_NAMESPACE _fl
6+
67
/* #undef _LIBCPP_ABI_FORCE_ITANIUM */
78
/* #undef _LIBCPP_ABI_FORCE_MICROSOFT */
89
/* #undef _LIBCPP_HIDE_FROM_ABI_PER_TU_BY_DEFAULT */

0 commit comments

Comments
 (0)