From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:46598) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WKcPr-0000mw-EV for qemu-devel@nongnu.org; Mon, 03 Mar 2014 18:37:03 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1WKcPn-0002xc-3A for qemu-devel@nongnu.org; Mon, 03 Mar 2014 18:36:59 -0500 Received: from static.92.5.9.176.clients.your-server.de ([176.9.5.92]:57411 helo=hallynmail2) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WKcPm-0002xT-RA for qemu-devel@nongnu.org; Mon, 03 Mar 2014 18:36:55 -0500 Date: Tue, 4 Mar 2014 00:36:52 +0100 From: "Serge E. Hallyn" Message-ID: <20140303233652.GA12334@mail.hallyn.com> References: <1393873716-9574-1-git-send-email-aneesh.kumar@linux.vnet.ibm.com> <5314D475.8070107@redhat.com> <87r46jvx99.fsf@linux.vnet.ibm.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <87r46jvx99.fsf@linux.vnet.ibm.com> Subject: Re: [Qemu-devel] [PATCH] hw/9pfs: Include virtio-9p-device.o in build List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: "Aneesh Kumar K.V" Cc: Paolo Bonzini , Fam Zheng , qemu-devel@nongnu.org Quoting Aneesh Kumar K.V (aneesh.kumar@linux.vnet.ibm.com): > Paolo Bonzini writes: > > > Il 03/03/2014 20:08, Aneesh Kumar K.V ha scritto: > >> From: "Aneesh Kumar K.V" > >> > >> After commit ba1183da9a10b94611cad88c44a5c6df005f9b55 we are including > >> hw/Makefile.objs directly from Makefile.target. Hence we need to define > >> the config in Makefile.target too to include virtio-9p-device.o in > >> the build > >> > >> Signed-off-by: Aneesh Kumar K.V > >> --- > >> Makefile.target | 4 ++++ > >> 1 file changed, 4 insertions(+) > >> > >> diff --git a/Makefile.target b/Makefile.target > >> index ba1234063eae..da8daa82c39e 100644 > >> --- a/Makefile.target > >> +++ b/Makefile.target > >> @@ -137,6 +137,10 @@ endif # CONFIG_SOFTMMU > >> # Workaround for http://gcc.gnu.org/PR55489, see configure. > >> %/translate.o: QEMU_CFLAGS += $(TRANSLATE_OPT_CFLAGS) > >> > >> +ifeq ($(CONFIG_VIRTIO)$(CONFIG_VIRTFS)$(CONFIG_PCI),yyy) > >> +CONFIG_REALLY_VIRTFS=y > >> +endif > >> + > >> dummy := $(call unnest-vars,,obj-y) > >> > >> # we are making another call to unnest-vars with different vars, protect obj-y, > >> > > > > Can you just replace $(CONFIG_REALLY_VIRTFS) with > > > > $(call land, $(call land, $(CONFIG_VIRTIO), > > $(CONFIG_VIRTFS)), > > $(CONFIG_PCI)) > > > > After multiple trial and error ended up with this. BTW where do i find > docs for land/lnot etc ? > > commit 01041f5df94ff19988cbadd7bd3eefcc9d964e4e > Author: Aneesh Kumar K.V > Date: Tue Mar 4 00:35:32 2014 +0530 > > hw/9pfs: Include virtio-9p-device.o in build > > After commit ba1183da9a10b94611cad88c44a5c6df005f9b55 we are including > hw/Makefile.objs directly from Makefile.target. Make sure hw/Makefile.objs > rules doesn't depend on variable defined in Makefile.objs > > Signed-off-by: Aneesh Kumar K.V Thanks, Aneesh, this worked for me. Tested-by: Serge Hallyn > > diff --git a/Makefile.objs b/Makefile.objs > index 4a62913a4d25..5cd3d816ffb0 100644 > --- a/Makefile.objs > +++ b/Makefile.objs > @@ -21,11 +21,6 @@ block-obj-y += coroutine-$(CONFIG_COROUTINE_BACKEND).o > > block-obj-m = block/ > > -ifeq ($(CONFIG_VIRTIO)$(CONFIG_VIRTFS)$(CONFIG_PCI),yyy) > -# Lots of the fsdev/9pcode is pulled in by vl.c via qemu_fsdev_add. > -# only pull in the actual virtio-9p device if we also enabled virtio. > -CONFIG_REALLY_VIRTFS=y > -endif > > ###################################################################### > # smartcard > diff --git a/fsdev/Makefile.objs b/fsdev/Makefile.objs > index 206289c49f18..c27dad3f6dc7 100644 > --- a/fsdev/Makefile.objs > +++ b/fsdev/Makefile.objs > @@ -1,4 +1,6 @@ > -ifeq ($(CONFIG_REALLY_VIRTFS),y) > +ifeq ($(CONFIG_VIRTIO)$(CONFIG_VIRTFS)$(CONFIG_PCI),yyy) > +# Lots of the fsdev/9pcode is pulled in by vl.c via qemu_fsdev_add. > +# only pull in the actual virtio-9p device if we also enabled virtio. > common-obj-y = qemu-fsdev.o virtio-9p-marshal.o > else > common-obj-y = qemu-fsdev-dummy.o > diff --git a/hw/Makefile.objs b/hw/Makefile.objs > index 05a00dc40133..d178b65de4d0 100644 > --- a/hw/Makefile.objs > +++ b/hw/Makefile.objs > @@ -1,4 +1,4 @@ > -devices-dirs-$(CONFIG_REALLY_VIRTFS) += 9pfs/ > +devices-dirs-$(call land, $(CONFIG_VIRTIO),$(call land,$(CONFIG_VIRTFS),$(CONFIG_PCI))) += 9pfs/ > devices-dirs-$(CONFIG_ACPI) += acpi/ > devices-dirs-$(CONFIG_SOFTMMU) += audio/ > devices-dirs-$(CONFIG_SOFTMMU) += block/ >