On 4/2/26 06:17, Philippe Mathieu-Daudé wrote:
> Neither of kvm.c nor hyp_gdbstub.c use target-specific code.
> Move them from arm_system_ss[] to arm_common_system_ss[] to
> compile them once. The arm_system_ss[] source set ends up
> unused, remove it.
>
> Signed-off-by: Philippe Mathieu-Daudé <philmd@linaro.org>
> ---
> target/arm/meson.build | 10 ++++++----
> 1 file changed, 6 insertions(+), 4 deletions(-)
Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
r~
>
> diff --git a/target/arm/meson.build b/target/arm/meson.build
> index f14debc6a2f..1b5d346d474 100644
> --- a/target/arm/meson.build
> +++ b/target/arm/meson.build
> @@ -1,7 +1,6 @@
> arm_ss = ss.source_set()
> arm_common_ss = ss.source_set()
> arm_common_system_ss = ss.source_set()
> -arm_system_ss = ss.source_set()
> arm_user_ss = ss.source_set()
>
> arm_common_system_ss.add(files('gdbstub.c'))
> @@ -19,7 +18,6 @@ arm_common_ss.add(files(
> arm_common_system_ss.add(files(
> 'arm-qmp-cmds.c',
> ))
> -arm_system_ss.add(when: 'CONFIG_KVM', if_true: files('hyp_gdbstub.c', 'kvm.c'))
>
> arm_user_ss.add(files('cpu.c'))
> arm_user_ss.add(when: 'TARGET_AARCH64', if_false: files(
> @@ -39,7 +37,12 @@ arm_user_ss.add(when: 'CONFIG_ARM_COMPATIBLE_SEMIHOSTING',
> arm_common_system_ss.add(files('cpu.c'))
> arm_common_system_ss.add(when: 'TARGET_AARCH64', if_false: files(
> 'cpu32-stubs.c'))
> -arm_common_system_ss.add(when: 'CONFIG_KVM', if_false: files('kvm-stub.c'))
> +arm_common_system_ss.add(when: 'CONFIG_KVM', if_true: files(
> + 'kvm.c',
> + 'hyp_gdbstub.c',
> +), if_false: files(
> + 'kvm-stub.c',
> +))
> arm_common_system_ss.add(when: 'CONFIG_HVF', if_true: files('hyp_gdbstub.c'))
> arm_common_system_ss.add(when: 'CONFIG_ARM_COMPATIBLE_SEMIHOSTING',
> if_true: files('common-semi-target.c'))
> @@ -67,7 +70,6 @@ else
> endif
>
> target_arch += {'arm': arm_ss}
> -target_system_arch += {'arm': arm_system_ss}
> target_user_arch += {'arm': arm_user_ss}
> target_common_arch += {'arm': arm_common_ss}
> target_common_system_arch += {'arm': arm_common_system_ss}