Skip to content

Commit 71edd05

Browse files
committed
[CHERI CSA] Add extra_scan_build_args project property
1 parent 7fac0ea commit 71edd05

2 files changed

Lines changed: 10 additions & 0 deletions

File tree

pycheribuild/projects/cross/cheribsd.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1930,6 +1930,10 @@ def setup_config_options(cls, kernel_only_target=False, install_directory_help=N
19301930
def can_build_with_csa(cls) -> bool:
19311931
return True
19321932

1933+
@classproperty
1934+
def extra_scan_build_args(self) -> list[str]:
1935+
return ["-disable-checker", "alpha.core.PointerSub"]
1936+
19331937
def __init__(self, *args, **kwargs) -> None:
19341938
super().__init__(*args, **kwargs)
19351939
self.extra_kernels_with_mfs: "list[str]" = []

pycheribuild/projects/project.py

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -508,6 +508,10 @@ def can_build_with_cfi(self) -> bool:
508508
def can_build_with_csa(self) -> bool:
509509
return False
510510

511+
@classproperty
512+
def extra_scan_build_args(self) -> list[str]:
513+
return []
514+
511515
@classproperty
512516
def can_build_with_ccache(self) -> bool:
513517
return False
@@ -1227,6 +1231,8 @@ def _get_scan_build_args(self) -> list[str]:
12271231
"--use-cc", commandline_to_str([self.CC]),
12281232
"--use-c++", commandline_to_str([self.CXX]),
12291233
]
1234+
if self.extra_scan_build_args:
1235+
scan_build_args = scan_build_args + self.extra_scan_build_args
12301236
return scan_build_args
12311237

12321238
def _get_make_commandline(

0 commit comments

Comments
 (0)