File tree Expand file tree Collapse file tree 1 file changed +13
-3
lines changed
documentation/cxx-interop/status Expand file tree Collapse file tree 1 file changed +13
-3
lines changed Original file line number Diff line number Diff line change @@ -79,10 +79,20 @@ code for a specific deployment platform:
7979| ** Ubuntu, CentOS, Amazon Linux** | libstdc++ |
8080| ** Windows** | Microsoft C++ Standard Library (msvcprt) |
8181
82+ Swift also supports selecting libc++ when building on certain Linux
83+ distributions by passing ` -Xcc -stdlib=libc++ ` flags. On those distributions,
84+ libc++ needs to be installed from a system package manager, e.g. apt or yum.
85+ This compatibility matrix shows the versions of libc++ that are supported by
86+ Swift when building for various Linux versions:
87+
88+ | Linux version running Swift application | Supported libc++ package |
89+ | -----------------------------------------| --------------------------|
90+ | Ubuntu 22.04 | libc++-15-dev |
91+ | Ubuntu 24.04 | libc++-18-dev |
92+
8293Swift does not currently support selecting an alternative standard library for
83- platforms that support alternative standard libraries. For example, you can't use
84- libc++ when building Swift code for Ubuntu, even though libc++ can be used when
85- building C++ code for Ubuntu.
94+ other platforms. For example, you can't use libc++ when building Swift code for
95+ Windows, even though libc++ can be used when building C++ code for Windows.
8696
8797Mixed Swift and C++ code must use
8898the same C++ standard library.
You can’t perform that action at this time.
0 commit comments