From: Michael Roth <mdroth@linux.vnet.ibm.com>
To: Stefano Stabellini <stefano.stabellini@eu.citrix.com>
Cc: "qemu-trivial@nongnu.org" <qemu-trivial@nongnu.org>,
Stefan Weil <sw@weilnetz.de>,
"qemu-devel@nongnu.org" <qemu-devel@nongnu.org>,
Stefan Hajnoczi <stefanha@gmail.com>
Subject: Re: [Qemu-devel] [Qemu-trivial] [PATCH 2/2] Makefile: use full path for qapi-generated directory
Date: Thu, 01 Dec 2011 10:05:02 -0600 [thread overview]
Message-ID: <4ED7A5AE.4000602@linux.vnet.ibm.com> (raw)
In-Reply-To: <alpine.DEB.2.00.1112011048150.31179@kaball-desktop>
On 12/01/2011 09:19 AM, Stefano Stabellini wrote:
> On Wed, 30 Nov 2011, Stefan Weil wrote:
>> It's common to use either out-of-tree builds or in-tree builds,
>> but not to mix both variants with a common root directory.
>> I think QEMU should explicitly forbid that mixed scenario (like
>> other projects do).
>>
>> Even with your fix there can remain problems with generated
>> header files.
>
> Really? Can you provide more specific details?
>
>> The mixed scenario creates unnecessary complexity.
>> Without the mixed scenario, your patch is not needed.
>
> I agree that supporting the mixed scenario shouldn't be a priority.
> However without this last patch a "make clean" on the main tree is not
> enough to allow out of tree builds.
>
> Try the following scenario:
>
> - cd qemu; ./configure; make
>
> - make clean
>
> - cd ../temp; ./configure --source-path=../qemu; make
>
> this has to work, right? It does not without the patch to fix the
> generation of config-devices.mak.
>
To clarify, the first patch I sent fix a bug that's not currently
triggered due to qapi-dir always ending up being "qapi-generated/", so
the guardname generated works, albeit with some needlessly verbose names.
The second isn't intended to fix your issue with builds, but avoid
potential problems that may arise if at some point $(BUILD_DIR) !=
$(CURDIR).
So they don't actually fix anything, just potential bugs that may arise
in the future.
The issue with doing out of tree builds with a dirty source directory is
really just an unsupported scenario. To really clean things up, you need
to run `make distclean` using the same configuration you used to dirty
the directory in the first place, otherwise even `make distclean` will
leave cruft laying in target directories not present in your current config.
Alexandre Raymond sent a patch to make it so that `make distclean`
always left the source directory pristine, but there was some contention
on what exactly a `make distclean` entails and it wasn't applied:
http://lists.gnu.org/archive/html/qemu-trivial/2011-07/msg00037.html
That's really the only complete fix for these build issues. I'm starting
to think it'd be worth it to add a `make clean_for_reals` target that
does what Alexandre's patch does and tell people to run it after a pull
or switching to out-of-tree builds.
next prev parent reply other threads:[~2011-12-01 16:05 UTC|newest]
Thread overview: 19+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-11-22 17:27 [Qemu-devel] [PATCH] fix out of tree build Stefano Stabellini
2011-11-23 9:48 ` [Qemu-devel] [Qemu-trivial] " Stefan Hajnoczi
2011-11-28 18:34 ` [Qemu-devel] " Stefan Weil
2011-11-28 18:45 ` Anthony Liguori
2011-11-28 20:40 ` Stefan Weil
2011-11-29 16:23 ` Stefano Stabellini
2011-11-29 22:47 ` [Qemu-devel] [PATCH 1/2] qapi: fix guardname generation Michael Roth
2011-11-29 22:47 ` [Qemu-devel] [PATCH 2/2] Makefile: use full path for qapi-generated directory Michael Roth
2011-11-30 9:10 ` [Qemu-devel] [Qemu-trivial] " Stefan Hajnoczi
2011-11-30 13:03 ` Stefano Stabellini
2011-11-30 19:59 ` Stefan Weil
2011-12-01 15:19 ` Stefano Stabellini
2011-12-01 16:05 ` Michael Roth [this message]
2011-12-01 18:11 ` Stefan Weil
2011-12-01 18:28 ` Anthony Liguori
2011-12-01 18:42 ` Stefano Stabellini
2011-12-01 19:12 ` Michael Roth
2011-12-01 18:38 ` Stefano Stabellini
2011-11-30 9:08 ` [Qemu-devel] [Qemu-trivial] [PATCH 1/2] qapi: fix guardname generation Stefan Hajnoczi
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=4ED7A5AE.4000602@linux.vnet.ibm.com \
--to=mdroth@linux.vnet.ibm.com \
--cc=qemu-devel@nongnu.org \
--cc=qemu-trivial@nongnu.org \
--cc=stefanha@gmail.com \
--cc=stefano.stabellini@eu.citrix.com \
--cc=sw@weilnetz.de \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).