From ed61d6a46611cfb144b260e0dd0fb1b5783562d9 Mon Sep 17 00:00:00 2001 From: Louis Dionne Date: Sat, 18 Mar 2023 13:34:29 -0400 Subject: [libc++] Use the stdlib= Lit feature instead of use_system_cxx_lib The use_system_cxx_lib Lit feature was only used for back-deployment testing. However, one immense hole in that setup was that we didn't have a proper way to test Apple's own libc++ outside of back-deployment, which was embodied by the fact that we needed to define _LIBCPP_DISABLE_AVAILABILITY when testing (see change in libcxx/utils/libcxx/test/params.py). This led to the apple-system testing configuration not checking for availability markup, which is obviously quite bad since the library we ship actually has availability markup. Using stdlib=-libc++ instead to encode back-deployment restrictions on tests is simpler and it makes it possible to naturally support tests such as availability markup checking even in the tip-of-trunk Apple-libc++ configuration. Differential Revision: https://reviews.llvm.org/D146366 --- libunwind/test/configs/apple-libunwind-backdeployment.cfg.in | 2 ++ libunwind/test/libunwind_01.pass.cpp | 2 +- 2 files changed, 3 insertions(+), 1 deletion(-) (limited to 'libunwind') diff --git a/libunwind/test/configs/apple-libunwind-backdeployment.cfg.in b/libunwind/test/configs/apple-libunwind-backdeployment.cfg.in index 4e37a2768e52..4484573801bd 100644 --- a/libunwind/test/configs/apple-libunwind-backdeployment.cfg.in +++ b/libunwind/test/configs/apple-libunwind-backdeployment.cfg.in @@ -54,6 +54,8 @@ config.substitutions.append(('%{exec}', '%{executor} --execdir %T --env DYLD_LIBRARY_PATH="%{cxx-runtime-root}:%{abi-runtime-root}:%{unwind-runtime-root}" -- ' )) +config.stdlib = 'apple-libc++' + import os, site import libcxx.test.params, libcxx.test.config libcxx.test.config.configure( diff --git a/libunwind/test/libunwind_01.pass.cpp b/libunwind/test/libunwind_01.pass.cpp index 4661ac9df821..96f12d1fc393 100644 --- a/libunwind/test/libunwind_01.pass.cpp +++ b/libunwind/test/libunwind_01.pass.cpp @@ -8,7 +8,7 @@ //===----------------------------------------------------------------------===// // TODO: Investigate this failure on x86_64 macOS back deployment -// XFAIL: use_system_cxx_lib && target=x86_64-apple-macosx{{10.9|10.10|10.11|10.12|10.13|10.14|10.15|11.0|12.0}} +// XFAIL: stdlib=apple-libc++ && target=x86_64-apple-macosx{{10.9|10.10|10.11|10.12|10.13|10.14|10.15|11.0|12.0}} // TODO: Figure out why this fails with Memory Sanitizer. // XFAIL: msan -- cgit v1.2.1