Patchwork [5/9] virtio: simplify Makefile conditionals

login
register
mail settings
Submitter Paolo Bonzini
Date April 19, 2013, 2:24 p.m.
Message ID <1366381460-6041-6-git-send-email-pbonzini@redhat.com>
Download mbox | patch
Permalink /patch/237990/
State New
Headers show

Comments

Paolo Bonzini - April 19, 2013, 2:24 p.m.
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
---
 hw/Makefile.objs        | 2 +-
 hw/virtio/Makefile.objs | 8 ++++----
 2 files changed, 5 insertions(+), 5 deletions(-)

Patch

diff --git a/hw/Makefile.objs b/hw/Makefile.objs
index b7a1613..0243d6a 100644
--- a/hw/Makefile.objs
+++ b/hw/Makefile.objs
@@ -24,7 +24,7 @@  devices-dirs-$(CONFIG_SOFTMMU) += ssi/
 devices-dirs-$(CONFIG_SOFTMMU) += timer/
 devices-dirs-$(CONFIG_TPM) += tpm/
 devices-dirs-$(CONFIG_SOFTMMU) += usb/
-devices-dirs-$(CONFIG_SOFTMMU) += virtio/
+devices-dirs-$(CONFIG_VIRTIO) += virtio/
 devices-dirs-$(CONFIG_SOFTMMU) += watchdog/
 devices-dirs-$(CONFIG_SOFTMMU) += xen/
 devices-dirs-y += core/
diff --git a/hw/virtio/Makefile.objs b/hw/virtio/Makefile.objs
index c7e8013..cbe6d51 100644
--- a/hw/virtio/Makefile.objs
+++ b/hw/virtio/Makefile.objs
@@ -1,7 +1,7 @@ 
-common-obj-$(CONFIG_VIRTIO) += virtio-rng.o
+common-obj-y += virtio-rng.o
 common-obj-$(CONFIG_VIRTIO_PCI) += virtio-pci.o
-common-obj-$(CONFIG_VIRTIO) += virtio-bus.o
+common-obj-y += virtio-bus.o
 common-obj-$(CONFIG_VIRTIO_BLK_DATA_PLANE) += dataplane/
 
-obj-$(CONFIG_VIRTIO) += virtio.o virtio-balloon.o 
-obj-$(CONFIG_VHOST_NET) += vhost.o
+obj-y += virtio.o virtio-balloon.o 
+obj-$(CONFIG_LINUX) += vhost.o