CodeQL / Analyze (actions) (push) Canceled after 0s
CodeQL / Analyze (python) (push) Canceled after 0s
pre-commit / pre-commit (push) Canceled after 0s
Multi-Arch CI / setup (push) Canceled after 0s
Publish build_manylinux_x86_64 images / publish_build_manylinux_x86_64 (push) Canceled after 0s
Setup (Multi-Arch) / setup (push) Canceled after 0s
Multi-Arch CI / Linux::${{ fromJSON(needs.setup.outputs.linux_build_config || '{}').build_variant_label || 'skip' }} (push) Canceled after 0s
Publish TheRock Docker image / build-and-push-image (push) Canceled after 0s
Publish no_rocm_image_ubi10 image / publish_no_rocm_image_ubi10 (push) Canceled after 0s
Multi-Arch CI / Windows::${{ fromJSON(needs.setup.outputs.windows_build_config || '{}').build_variant_label || 'skip' }} (push) Canceled after 0s
Publish TheRock Docker image / build-and-push-image (push) Canceled after 0s
Multi-Arch CI / Manifest Diff (push) Canceled after 0s
TheRock Manifest Diff Report / Generate Manifest Diff Report (push) Canceled after 0s
Multi-Arch CI / CI Summary (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04 images / publish_no_rocm_image_ubuntu24_04 (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04_ocl_rt images / publish_no_rocm_image_ubuntu24_04_ocl_rt (push) Canceled after 0s
Publish TheRock Docker image / build-and-push-image (push) Canceled after 0s
Publish TheRock Docker image / build-and-push-image (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04 images / publish_no_rocm_image_ubuntu24_04_rocgdb (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04_rocgdb images / publish_no_rocm_image_ubuntu24_04_rocgdb (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04 images / publish_no_rocm_image_ubuntu24_04_ocl_rt (push) Canceled after 0s
Publish TheRock Docker image / build-and-push-image (push) Canceled after 0s
Unit Tests / Unit Tests :: ubuntu-24.04 (push) Canceled after 0s
Unit Tests / Unit Tests :: windows-2022 (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04 images / publish_no_rocm_image_ubuntu24_04_media (push) Canceled after 0s
Unit Tests / Unit Tests Summary (push) Canceled after 0s
Publish no_rocm_image_ubuntu24_04 images / publish_no_rocm_image_ubuntu24_04_openmpi (push) Canceled after 0s
75 lines
2.0 KiB
Python
75 lines
2.0 KiB
Python
# -*- Python -*-
|
|
|
|
import os
|
|
|
|
# Setup config name.
|
|
config.name = "Scudo" + config.name_suffix
|
|
|
|
# Setup source root.
|
|
config.test_source_root = os.path.dirname(__file__)
|
|
|
|
# Path to the shared library
|
|
shared_libscudo = os.path.join(
|
|
config.compiler_rt_libdir, "libclang_rt.scudo%s.so" % config.target_suffix
|
|
)
|
|
shared_minlibscudo = os.path.join(
|
|
config.compiler_rt_libdir, "libclang_rt.scudo_minimal%s.so" % config.target_suffix
|
|
)
|
|
|
|
# Test suffixes.
|
|
config.suffixes = [".c", ".cpp", ".test"]
|
|
|
|
# C & CXX flags.
|
|
c_flags = [config.target_cflags] + [
|
|
"-pthread",
|
|
"-fPIE",
|
|
"-pie",
|
|
"-O0",
|
|
"-UNDEBUG",
|
|
"-ldl",
|
|
"-Wl,--gc-sections",
|
|
]
|
|
|
|
# Android doesn't want -lrt.
|
|
if not config.android:
|
|
c_flags += ["-lrt"]
|
|
|
|
cxx_flags = c_flags + config.cxx_mode_flags + ["-std=c++11"]
|
|
|
|
scudo_flags = ["-fsanitize=scudo"]
|
|
|
|
|
|
def build_invocation(compile_flags):
|
|
return " " + " ".join([config.clang] + compile_flags) + " "
|
|
|
|
|
|
# Add substitutions.
|
|
config.substitutions.append(("%clang ", build_invocation(c_flags)))
|
|
config.substitutions.append(("%clang_scudo ", build_invocation(c_flags + scudo_flags)))
|
|
config.substitutions.append(
|
|
("%clangxx_scudo ", build_invocation(cxx_flags + scudo_flags))
|
|
)
|
|
config.substitutions.append(("%shared_libscudo", shared_libscudo))
|
|
config.substitutions.append(("%shared_minlibscudo", shared_minlibscudo))
|
|
|
|
# Platform-specific default SCUDO_OPTIONS for lit tests.
|
|
default_scudo_opts = ""
|
|
if config.android:
|
|
# Android defaults to abort_on_error=1, which doesn't work for us.
|
|
default_scudo_opts = "abort_on_error=0"
|
|
|
|
# Disable GWP-ASan for scudo internal tests.
|
|
if config.gwp_asan:
|
|
config.environment["GWP_ASAN_OPTIONS"] = "Enabled=0"
|
|
|
|
if default_scudo_opts:
|
|
config.environment["SCUDO_OPTIONS"] = default_scudo_opts
|
|
default_scudo_opts += ":"
|
|
config.substitutions.append(
|
|
("%env_scudo_opts=", "env SCUDO_OPTIONS=" + default_scudo_opts)
|
|
)
|
|
|
|
# Hardened Allocator tests are currently supported on Linux only.
|
|
if config.target_os not in ["Linux"]:
|
|
config.unsupported = True
|