mirror of
https://github.com/OpenRTX/OpenRTX
synced 2024-10-16 09:55:39 +00:00
Add undefined behaviour sanitizer option
This commit is contained in:
parent
c752601463
commit
9aefde7fc7
@ -280,6 +280,11 @@ if get_option('asan')
|
|||||||
linux_c_args += '-fsanitize=address'
|
linux_c_args += '-fsanitize=address'
|
||||||
linux_l_args += '-fsanitize=address'
|
linux_l_args += '-fsanitize=address'
|
||||||
endif
|
endif
|
||||||
|
# Add Undefined Behaviour Sanitizer if required
|
||||||
|
if get_option('ubsan')
|
||||||
|
linux_c_args += '-fsanitize=undefined'
|
||||||
|
linux_l_args += '-fsanitize=undefined'
|
||||||
|
endif
|
||||||
|
|
||||||
foreach k, v : linux_def
|
foreach k, v : linux_def
|
||||||
if v == ''
|
if v == ''
|
||||||
|
@ -1,2 +1,3 @@
|
|||||||
option('asan', type : 'boolean', value : false, description : 'Compile the software with AddressSanitizer')
|
option('asan', type : 'boolean', value : false, description : 'Compile the software with AddressSanitizer')
|
||||||
|
option('ubsan', type : 'boolean', value : false, description : 'Compile the software with Undefined Behaviour Sanitizer')
|
||||||
option('test', type: 'string', description: 'Replace the main OpenRTX source file with a specialized test')
|
option('test', type: 'string', description: 'Replace the main OpenRTX source file with a specialized test')
|
||||||
|
Loading…
Reference in New Issue
Block a user