From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1NHjCl-00082Q-RY for qemu-devel@nongnu.org; Mon, 07 Dec 2009 14:25:08 -0500 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1NHjCh-0007xV-5v for qemu-devel@nongnu.org; Mon, 07 Dec 2009 14:25:07 -0500 Received: from [199.232.76.173] (port=59551 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1NHjCg-0007x9-Sl for qemu-devel@nongnu.org; Mon, 07 Dec 2009 14:25:02 -0500 Received: from mx1.redhat.com ([209.132.183.28]:1054) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1NHjCg-0001ep-Jt for qemu-devel@nongnu.org; Mon, 07 Dec 2009 14:25:02 -0500 Date: Mon, 7 Dec 2009 21:22:17 +0200 From: "Michael S. Tsirkin" Message-ID: <20091207192217.GC5734@redhat.com> References: <20091207094240.GB31370@redhat.com> <4B1D391E.9060809@codemonkey.ws> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <4B1D391E.9060809@codemonkey.ws> Subject: [Qemu-devel] Re: run make defconfig List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Anthony Liguori Cc: qemu-devel@nongnu.org, Juan Quintela On Mon, Dec 07, 2009 at 11:19:26AM -0600, Anthony Liguori wrote: > Michael S. Tsirkin wrote: >> OK, I got the "Run make defconfig" message again. >> I think it used to be re-run automatically: why >> are we asking the user to do it manually now? >> > It's buggy. defconfig should only be needed when a new config option is > added and the old config doesn't contain it yet. > > But we get this message often when a new config option has not been > added. I suspect it has something to do with checks on accessed time > against configure and config*. We probably need to be smarter than that. > > Regards, > > Anthony Liguori Could you tell me what is it supposed to do? Here's code with my commentary: config-all-devices.mak: $(SUBDIR_DEVICES_MAK) $(call quiet-command,cat $(SUBDIR_DEVICES_MAK) | grep =y | sort -u > $@," GEN $@") # so there's config-all-devices.mak which includes all =y lines from SUBDIR_DEVICES_MAK. %/config-devices.mak: default-configs/%.mak # this is run if # default-configs/%.mak exists and %/config-devices.mak # is older than default-configs/%.mak $(call quiet-command,cat $< > $@.tmp, " GEN $@") # simply cat default-configs/%.mak to a temporary file @if test -f $@ ; then \ # check whether %/config-devices.mak exists echo "WARNING: $@ out of date." ;\ echo "Run \"make defconfig\" to regenerate." ; \ rm $@.tmp ; \ #if yes tell user to run make defconfig and remove temporary # so why generate in the first place? else \ mv $@.tmp $@ ; \ #if no move temporary to %/config-devices.mak fi defconfig: rm -f config-all-devices.mak $(SUBDIR_DEVICES_MAK) # this removes config-all-devices.mak and all SUBDIR_DEVICES_MAK Now in targets, we have include config-devices.mak So my conclusions are: - The only way to generate config-devices.mak seems to be to copy default-configs.mak - We get warning each time timestamp for default configs changes. - Annoyingly, this warning will be present when you run make defconfig itself or when you run make clean Proposal: why don't we just make %/config-devices.mak include default-configs/%.mak? No copy will be necessary. -- MST