test-runner: Implement is_debugger_attached() for FreeBSD

FreeBSD provides a PROC_TRACE_STATUS procctl(2) to detect this directly.

Signed-off-by: Alex Richardson <Alexander.Richardson@cl.cam.ac.uk>
This commit is contained in:
Alex Richardson 2021-03-15 22:37:49 +00:00 committed by Alexander Richardson
parent 644efe9517
commit bb92828807
2 changed files with 23 additions and 1 deletions

View file

@ -26,7 +26,7 @@ add_project_arguments(
language: 'c'
)
foreach h: [ 'sys/prctl.h', 'sys/ucred.h' ]
foreach h: [ 'sys/prctl.h', 'sys/procctl.h', 'sys/ucred.h' ]
config_h.set('HAVE_' + h.underscorify().to_upper(), cc.has_header(h))
endforeach