cosmopolitan/third_party
Trung Nguyen 8b33204f37
Add LLVM libcxxabi (#1063)
* third_party: Add libcxxabi

Added libcxxabi from LLVM 17.0.6
The library implements the Itanium C++ exception handling ABI.

* third_party/libcxxabi: Enable __cxa_thread_atexit

Enable `__cxa_thread_atexit` from libcxxabi.
`__cxa_thread_atexit_impl` is still implemented by the cosmo libc.
The original `__cxa_thread_atexit` has been removed.

* third_party/libcxx: Build with exceptions

Build libcxx with exceptions enabled.

- Removed `_LIBCPP_NO_EXCEPTIONS` from `__config`.
- Switched the exception implementation to `libcxxabi`. These two files
are taken from the same `libcxx` version as mentioned in `README.cosmo`.
- Removed `new_handler_fallback` in favor of `libcxxabi` implementation.
- Enable `-fexceptions` and `-frtti` for `libcxx`.
- Removed `THIRD_PARTY_LIBCXX` dependency from `libcxxabi` and
`libunwind`. These libraries do not use any runtime `libcxx` functions,
just headers.

* libc: Remove remaining redundant cxa functions

- `__cxa_pure_virtual` in `libcxxabi` is also a stub similar to the
existing one.
- `__cxa_guard_*` from `libcxxabi` is used instead of the ones from
Android.

Now there should be no more duplicate implementations.
`__cxa_thread_atexit_impl`, `__cxa_atexit`, and related supporting
functions, are still left to other libraries as in `libcxxabi`.

`libcxxabi` is also now added to `cosmopolitan.a` to make up for the
removed functions.

Affected in-tree libraries (`third_party/double-conversion`) have been
updated.
2024-01-08 08:45:10 -08:00
..
aarch64 more modeline errata (#1019) 2023-12-16 23:07:10 -05:00
argon2 more modeline errata (#1019) 2023-12-16 23:07:10 -05:00
awk more modeline errata (#1019) 2023-12-16 23:07:10 -05:00
bash Add /dev/fd support to Windows 2024-01-06 18:20:21 -08:00
bzip2 more modeline errata (#1019) 2023-12-16 23:07:10 -05:00
chibicc more modeline errata (#1019) 2023-12-16 23:07:10 -05:00
compiler_rt more modeline errata (#1019) 2023-12-16 23:07:10 -05:00
ctags more modeline errata (#1019) 2023-12-16 23:07:10 -05:00
dlmalloc Use good locks in dlmalloc 2023-12-28 04:57:36 -08:00
double-conversion Add LLVM libcxxabi (#1063) 2024-01-08 08:45:10 -08:00
finger Use DNS implementation from Musl Libc 2023-12-28 23:04:35 -08:00
gdtoa more modeline errata (#1019) 2023-12-16 23:07:10 -05:00
getopt more modeline errata (#1019) 2023-12-16 23:07:10 -05:00
hiredis Use DNS implementation from Musl Libc 2023-12-28 23:04:35 -08:00
intel more modeline errata (#1019) 2023-12-16 23:07:10 -05:00
less more modeline errata (#1019) 2023-12-16 23:07:10 -05:00
libcxx Add LLVM libcxxabi (#1063) 2024-01-08 08:45:10 -08:00
libcxxabi Add LLVM libcxxabi (#1063) 2024-01-08 08:45:10 -08:00
libunwind Add LLVM libcxxabi (#1063) 2024-01-08 08:45:10 -08:00
linenoise more modeline errata (#1019) 2023-12-16 23:07:10 -05:00
lua Use DNS implementation from Musl Libc 2023-12-28 23:04:35 -08:00
lz4cli more modeline errata (#1019) 2023-12-16 23:07:10 -05:00
make Give GNU Make limitless stacks 2024-01-04 03:26:26 -08:00
maxmind more modeline errata (#1019) 2023-12-16 23:07:10 -05:00
mbedtls Use DNS implementation from Musl Libc 2023-12-28 23:04:35 -08:00
musl Fix bugs with DNS library on Windows 2024-01-03 17:39:57 -08:00
ncurses more modeline errata (#1019) 2023-12-16 23:07:10 -05:00
nsync more modeline errata (#1019) 2023-12-16 23:07:10 -05:00
pcre more modeline errata (#1019) 2023-12-16 23:07:10 -05:00
puff more modeline errata (#1019) 2023-12-16 23:07:10 -05:00
python Disable Python test_resource 2024-01-07 11:36:31 -08:00
qemu more modeline errata (#1019) 2023-12-16 23:07:10 -05:00
quickjs more modeline errata (#1019) 2023-12-16 23:07:10 -05:00
readline Fix --ftrace on Windows 2024-01-01 00:00:42 -08:00
regex more modeline errata (#1019) 2023-12-16 23:07:10 -05:00
sed more modeline errata (#1019) 2023-12-16 23:07:10 -05:00
smallz4 more modeline errata (#1019) 2023-12-16 23:07:10 -05:00
sqlite3 more modeline errata (#1019) 2023-12-16 23:07:10 -05:00
stb Use DNS implementation from Musl Libc 2023-12-28 23:04:35 -08:00
tidy more modeline errata (#1019) 2023-12-16 23:07:10 -05:00
tr more modeline errata (#1019) 2023-12-16 23:07:10 -05:00
tree more modeline errata (#1019) 2023-12-16 23:07:10 -05:00
unzip more modeline errata (#1019) 2023-12-16 23:07:10 -05:00
vqsort more modeline errata (#1019) 2023-12-16 23:07:10 -05:00
xed more modeline errata (#1019) 2023-12-16 23:07:10 -05:00
xxhash more modeline errata (#1019) 2023-12-16 23:07:10 -05:00
zip more modeline errata (#1019) 2023-12-16 23:07:10 -05:00
zlib more modeline errata (#1019) 2023-12-16 23:07:10 -05:00
zstd more modeline errata (#1019) 2023-12-16 23:07:10 -05:00
.clang-format Reduce header complexity 2023-11-28 14:39:42 -08:00
BUILD.mk Add LLVM libcxxabi (#1063) 2024-01-08 08:45:10 -08:00