meson: convert hw/smbios

Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
Reviewed-by: Philippe Mathieu-Daudé <philmd@redhat.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
This commit is contained in:
Marc-André Lureau 2019-08-15 15:39:54 +04:00 committed by Paolo Bonzini
parent b908c370f7
commit d6c9b1f003
4 changed files with 14 additions and 11 deletions

View File

@ -35,7 +35,6 @@ devices-dirs-$(CONFIG_VFIO) += vfio/
devices-dirs-y += virtio/
devices-dirs-y += watchdog/
devices-dirs-$(CONFIG_MEM_DEVICE) += mem/
devices-dirs-y += smbios/
endif
common-obj-y += $(devices-dirs-y)

View File

@ -1,4 +1,5 @@
subdir('core')
subdir('nubus')
subdir('semihosting')
subdir('smbios')
subdir('xen')

View File

@ -1,10 +0,0 @@
ifeq ($(CONFIG_SMBIOS),y)
common-obj-y += smbios.o
common-obj-$(CONFIG_IPMI) += smbios_type_38.o
common-obj-$(call lnot,$(CONFIG_IPMI)) += smbios_type_38-stub.o
else
common-obj-y += smbios-stub.o
endif
common-obj-$(CONFIG_ALL) += smbios-stub.o
common-obj-$(CONFIG_ALL) += smbios_type_38-stub.o

13
hw/smbios/meson.build Normal file
View File

@ -0,0 +1,13 @@
smbios_ss = ss.source_set()
smbios_ss.add(files('smbios.c'))
smbios_ss.add(when: 'CONFIG_IPMI',
if_true: files('smbios_type_38.c'),
if_false: files('smbios_type_38-stub.c'))
softmmu_ss.add_all(when: 'CONFIG_SMBIOS', if_true: smbios_ss)
softmmu_ss.add(when: 'CONFIG_SMBIOS', if_false: files('smbios-stub.c'))
softmmu_ss.add(when: 'CONFIG_ALL', if_true: files(
'smbios-stub.c',
'smbios_type_38-stub.c',
))