From: Eric Blake Subject: Re: [PATCH v2 1/2] make: move generated headers to qemu-build/ Date: Thu, 22 Mar 2018 14:42:55 -0500 Message-ID: References: <1521746188-496856-1-git-send-email-mst@redhat.com> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 7bit Cc: Peter Maydell , Dmitry Fleytman , Pavel Dovgalyuk , Li Zhijian , David Hildenbrand , Stefan Hajnoczi , BALATON Zoltan , Keith Busch , Max Filippov , Hannes Reinecke , Gerd Hoffmann , Fam Zheng , Max Reitz , Yongbok Kim , Stefano Stabellini , zhanghailiang , Ben Warren , Stefan Berger , Michael Roth , "Richard W.M. Jones" , Christian Borntraeger , =?UTF-8?Q?Herv=c3=a9_Poussineau?= , qemu-devel@nongnu.org Return-path: In-Reply-To: <1521746188-496856-1-git-send-email-mst@redhat.com> Content-Language: en-US List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-block-bounces+gceqb-qemu-block=m.gmane.org@nongnu.org Sender: "Qemu-block" List-Id: kvm.vger.kernel.org On 03/22/2018 02:27 PM, Michael S. Tsirkin wrote: > Make sure all generated files go into qemu-build subdirectory. > We can then include them like this: > #include "qemu-build/trace.h" > > This serves two purposes: > - make it easy to detect which files are in the source > directory (a bit more work for writers, easier for readers) > - reduce chances of conflicts with possible stale files in source > directory (which could be left over from e.g. old patches, etc) > > This patch needs to be merged with patch 2 of series updating all > files: sending it separately to avoid spamming the list. > > Signed-off-by: Michael S. Tsirkin > --- > +++ b/Makefile > @@ -89,102 +89,102 @@ endif > > include $(SRC_PATH)/rules.mak > > -GENERATED_FILES = qemu-version.h config-host.h qemu-options.def > -GENERATED_FILES += qapi/qapi-builtin-types.h qapi/qapi-builtin-types.c Uggh - I really need to follow up on my threat to make smarter use of make variables and string manipulation to cut down on the boilerplate involved here. Sadly, I'm not convinced that doing so is a 2.12 bugfix priority, so it isn't at the top of my work queue. Overall, the patch is an interesting idea. I'm still not 100% sold on it (as you say, it's now slightly more work for writers), but I'm not coming up with any solid reasons why it should not be applied (at least, for 2.13 - doing it during freeze for 2.12 is a bit harder to justify). -- Eric Blake, Principal Software Engineer Red Hat, Inc. +1-919-301-3266 Virtualization: qemu.org | libvirt.org