Skip to content
This repository was archived by the owner on Mar 7, 2026. It is now read-only.

Commit 5ab9a39

Browse files
committed
meson: decouple enable_riscv_accel from the debug target configuration
although it is tied to the debug target configuration being dependent on riscv_jtag_dtm, this option just sets a define and is better grouped with other similar configuration options
1 parent 7ff7b9e commit 5ab9a39

2 files changed

Lines changed: 7 additions & 16 deletions

File tree

src/meson.build

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -86,6 +86,12 @@ if advertise_noackmode
8686
libbmd_core_args += ['-DADVERTISE_NOACKMODE=1']
8787
endif
8888

89+
# Check if we should enable the RISC-V Debug remote protocol acceleration and do so if required
90+
enable_riscv_accel = get_option('enable_riscv_accel')
91+
if enable_riscv_accel
92+
bmd_core_args += ['-DCONFIG_RISCV_ACCEL=1']
93+
endif
94+
8995
# Get BMD targets dependency
9096
subdir('target')
9197

@@ -118,6 +124,7 @@ summary(
118124
'Debug output': debug_output,
119125
'RTT support': rtt_support,
120126
'Advertise QStartNoAckMode': advertise_noackmode,
127+
'RISC-V acceleration': enable_riscv_accel,
121128
},
122129
bool_yn: true,
123130
section: 'Black Magic Debug',

src/target/meson.build

Lines changed: 0 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -399,22 +399,6 @@ if is_firmware_build
399399
enabled_target_deps += get_variable(f'target_@target@')
400400
endforeach
401401

402-
# Check if we should enable the RISC-V Debug remote protocol acceleration and do so if required
403-
enable_riscv_accel = get_option('enable_riscv_accel')
404-
if enable_riscv_accel
405-
enabled_target_deps += declare_dependency(
406-
compile_args: ['-DCONFIG_RISCV_ACCEL=1'],
407-
dependencies: riscv_jtag_dtm,
408-
)
409-
endif
410-
411-
summary(
412-
'RISC-V acceleration',
413-
enable_riscv_accel,
414-
bool_yn: true,
415-
section: 'Remote Protocol',
416-
)
417-
418402
# BMD target dependency
419403
bmd_targets = declare_dependency(
420404
include_directories: target_common_includes,

0 commit comments

Comments
 (0)