diff options
author | 2021-03-01 23:56:57 +0100 | |
---|---|---|
committer | 2021-03-01 23:58:06 +0100 | |
commit | 566059c6b81614bc9640f854f91cab1bc0e724c3 (patch) | |
tree | 9244c2a3b7a00055d380b2628bfae7064a82a084 /sys-libs/compiler-rt-sanitizers | |
parent | dev-lang/python: Bump to 3.10.0a6 (diff) | |
download | gentoo-566059c6b81614bc9640f854f91cab1bc0e724c3.tar.gz gentoo-566059c6b81614bc9640f854f91cab1bc0e724c3.tar.bz2 gentoo-566059c6b81614bc9640f854f91cab1bc0e724c3.zip |
sys-libs/compiler-rt-sanitizers: Relax the component constraints
Relax the component constraints to apply only with USE=test. Reverse
the constraint between ubsan and cfi -- it is cfi that requires ubsan
for its tests to work. At the same time, stub out automagically enabled
cfi tests when ubsan is enabled but cfi is not. This should fix
impossible constraints on architectures that support ubsan but not cfi.
Closes: https://bugs.gentoo.org/773661
Signed-off-by: Michał Górny <mgorny@gentoo.org>
Diffstat (limited to 'sys-libs/compiler-rt-sanitizers')
5 files changed, 40 insertions, 15 deletions
diff --git a/sys-libs/compiler-rt-sanitizers/compiler-rt-sanitizers-11.0.1.ebuild b/sys-libs/compiler-rt-sanitizers/compiler-rt-sanitizers-11.0.1.ebuild index c7da5f747b37..d139a2006ac3 100644 --- a/sys-libs/compiler-rt-sanitizers/compiler-rt-sanitizers-11.0.1.ebuild +++ b/sys-libs/compiler-rt-sanitizers/compiler-rt-sanitizers-11.0.1.ebuild @@ -24,8 +24,10 @@ SANITIZER_FLAGS=( IUSE+=" ${SANITIZER_FLAGS[@]/#/+}" REQUIRED_USE=" || ( ${SANITIZER_FLAGS[*]} libfuzzer profile xray ) - gwp-asan? ( scudo ) - ubsan? ( cfi )" + test? ( + cfi? ( ubsan ) + gwp-asan? ( scudo ) + )" RESTRICT="!test? ( test ) !clang? ( test )" CLANG_SLOT=${SLOT%%.*} @@ -86,10 +88,13 @@ src_prepare() { fi done + # TODO: fix these tests to be skipped upstream if use asan && ! use profile; then - # TODO: fix these tests to be skipped upstream rm test/asan/TestCases/asan_and_llvm_coverage_test.cpp || die fi + if use ubsan && ! use cfi; then + > test/cfi/CMakeLists.txt || die + fi # broken with new glibc sed -i -e '/EXPECT_EQ.*ThreadDescriptorSize/d' \ diff --git a/sys-libs/compiler-rt-sanitizers/compiler-rt-sanitizers-11.1.0.ebuild b/sys-libs/compiler-rt-sanitizers/compiler-rt-sanitizers-11.1.0.ebuild index 5ae20f93336f..c877ae4241f1 100644 --- a/sys-libs/compiler-rt-sanitizers/compiler-rt-sanitizers-11.1.0.ebuild +++ b/sys-libs/compiler-rt-sanitizers/compiler-rt-sanitizers-11.1.0.ebuild @@ -24,8 +24,10 @@ SANITIZER_FLAGS=( IUSE+=" ${SANITIZER_FLAGS[@]/#/+}" REQUIRED_USE=" || ( ${SANITIZER_FLAGS[*]} libfuzzer profile xray ) - gwp-asan? ( scudo ) - ubsan? ( cfi )" + test? ( + cfi? ( ubsan ) + gwp-asan? ( scudo ) + )" RESTRICT="!test? ( test ) !clang? ( test )" CLANG_SLOT=${SLOT%%.*} @@ -86,10 +88,13 @@ src_prepare() { fi done + # TODO: fix these tests to be skipped upstream if use asan && ! use profile; then - # TODO: fix these tests to be skipped upstream rm test/asan/TestCases/asan_and_llvm_coverage_test.cpp || die fi + if use ubsan && ! use cfi; then + > test/cfi/CMakeLists.txt || die + fi # broken with new glibc sed -i -e '/EXPECT_EQ.*ThreadDescriptorSize/d' \ diff --git a/sys-libs/compiler-rt-sanitizers/compiler-rt-sanitizers-12.0.0.9999.ebuild b/sys-libs/compiler-rt-sanitizers/compiler-rt-sanitizers-12.0.0.9999.ebuild index 5fc5bbc62475..b9f483144cde 100644 --- a/sys-libs/compiler-rt-sanitizers/compiler-rt-sanitizers-12.0.0.9999.ebuild +++ b/sys-libs/compiler-rt-sanitizers/compiler-rt-sanitizers-12.0.0.9999.ebuild @@ -24,8 +24,10 @@ SANITIZER_FLAGS=( IUSE+=" ${SANITIZER_FLAGS[@]/#/+}" REQUIRED_USE=" || ( ${SANITIZER_FLAGS[*]} libfuzzer profile xray ) - gwp-asan? ( scudo ) - ubsan? ( cfi )" + test? ( + cfi? ( ubsan ) + gwp-asan? ( scudo ) + )" RESTRICT="!test? ( test ) !clang? ( test )" CLANG_SLOT=${SLOT%%.*} @@ -86,10 +88,13 @@ src_prepare() { fi done + # TODO: fix these tests to be skipped upstream if use asan && ! use profile; then - # TODO: fix these tests to be skipped upstream rm test/asan/TestCases/asan_and_llvm_coverage_test.cpp || die fi + if use ubsan && ! use cfi; then + > test/cfi/CMakeLists.txt || die + fi llvm.org_src_prepare } diff --git a/sys-libs/compiler-rt-sanitizers/compiler-rt-sanitizers-12.0.0_rc2.ebuild b/sys-libs/compiler-rt-sanitizers/compiler-rt-sanitizers-12.0.0_rc2.ebuild index 5fc5bbc62475..b9f483144cde 100644 --- a/sys-libs/compiler-rt-sanitizers/compiler-rt-sanitizers-12.0.0_rc2.ebuild +++ b/sys-libs/compiler-rt-sanitizers/compiler-rt-sanitizers-12.0.0_rc2.ebuild @@ -24,8 +24,10 @@ SANITIZER_FLAGS=( IUSE+=" ${SANITIZER_FLAGS[@]/#/+}" REQUIRED_USE=" || ( ${SANITIZER_FLAGS[*]} libfuzzer profile xray ) - gwp-asan? ( scudo ) - ubsan? ( cfi )" + test? ( + cfi? ( ubsan ) + gwp-asan? ( scudo ) + )" RESTRICT="!test? ( test ) !clang? ( test )" CLANG_SLOT=${SLOT%%.*} @@ -86,10 +88,13 @@ src_prepare() { fi done + # TODO: fix these tests to be skipped upstream if use asan && ! use profile; then - # TODO: fix these tests to be skipped upstream rm test/asan/TestCases/asan_and_llvm_coverage_test.cpp || die fi + if use ubsan && ! use cfi; then + > test/cfi/CMakeLists.txt || die + fi llvm.org_src_prepare } diff --git a/sys-libs/compiler-rt-sanitizers/compiler-rt-sanitizers-13.0.0.9999.ebuild b/sys-libs/compiler-rt-sanitizers/compiler-rt-sanitizers-13.0.0.9999.ebuild index 5fc5bbc62475..b9f483144cde 100644 --- a/sys-libs/compiler-rt-sanitizers/compiler-rt-sanitizers-13.0.0.9999.ebuild +++ b/sys-libs/compiler-rt-sanitizers/compiler-rt-sanitizers-13.0.0.9999.ebuild @@ -24,8 +24,10 @@ SANITIZER_FLAGS=( IUSE+=" ${SANITIZER_FLAGS[@]/#/+}" REQUIRED_USE=" || ( ${SANITIZER_FLAGS[*]} libfuzzer profile xray ) - gwp-asan? ( scudo ) - ubsan? ( cfi )" + test? ( + cfi? ( ubsan ) + gwp-asan? ( scudo ) + )" RESTRICT="!test? ( test ) !clang? ( test )" CLANG_SLOT=${SLOT%%.*} @@ -86,10 +88,13 @@ src_prepare() { fi done + # TODO: fix these tests to be skipped upstream if use asan && ! use profile; then - # TODO: fix these tests to be skipped upstream rm test/asan/TestCases/asan_and_llvm_coverage_test.cpp || die fi + if use ubsan && ! use cfi; then + > test/cfi/CMakeLists.txt || die + fi llvm.org_src_prepare } |