@@ -136,10 +136,6 @@ endif #CONFIG_BSD_USER
#########################################################
# System emulator target
ifdef CONFIG_SOFTMMU
-obj-y += arch_init.o cpus.o gdbstub.o balloon.o ioport.o
-obj-y += qtest.o
-obj-y += memory.o
-obj-y += memory_mapping.o
LIBS := $(libs_softmmu) $(LIBS)
# Temporary until emulators are linked by Meson
@@ -508,6 +508,18 @@ specific_ss.add(when: 'CONFIG_TCG', if_true: files(
))
specific_ss.add(when: 'CONFIG_TCG_INTERPRETER', if_true: files('disas/tci.c', 'tcg/tci.c'))
+specific_ss.add(when: 'CONFIG_SOFTMMU', if_true: files(
+ 'arch_init.c',
+ 'balloon.c',
+ 'cpus.c',
+ 'gdbstub.c',
+ 'ioport.c',
+ 'memory.c',
+ 'memory_mapping.c',
+ 'migration/ram.c',
+ 'qtest.c',
+))
+
# TODO: add each directory to the subdirs from its own meson.build, once
# we have those
trace_events_subdirs = [