mirror of
https://github.com/blackmagic-debug/blackmagic.git
synced 2025-10-14 02:58:36 +08:00
meson: Add CONFIG_POINTER_SIZE define
This allows detecting the pointer size of the machine running the code. Signed-off-by: Mary Guillemard <mary@mary.zone>
This commit is contained in:
@@ -160,6 +160,12 @@ if is_firmware_build and get_option('print_memory_usage')
|
||||
add_project_link_arguments('-Wl,--print-memory-usage', language: 'c')
|
||||
endif
|
||||
|
||||
# We need to know the size of a pointer for the machine running the code
|
||||
add_project_link_arguments('-DCONFIG_POINTER_SIZE=@0@'.format(cc_host.sizeof('void *')), language: 'c')
|
||||
if is_cross_build
|
||||
add_project_link_arguments('-DCONFIG_POINTER_SIZE=@0@'.format(cc_native.sizeof('void *')), language: 'c', native: true)
|
||||
endif
|
||||
|
||||
subdir('src')
|
||||
|
||||
## Black Magic Firmware (BMF) targets
|
||||
|
Reference in New Issue
Block a user