From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:59173) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Z0tM3-0001lw-E1 for qemu-devel@nongnu.org; Fri, 05 Jun 2015 11:16:21 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Z0tM0-0007LV-N9 for qemu-devel@nongnu.org; Fri, 05 Jun 2015 11:16:19 -0400 Received: from mx1.redhat.com ([209.132.183.28]:52407) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Z0tM0-0007L4-Ho for qemu-devel@nongnu.org; Fri, 05 Jun 2015 11:16:16 -0400 From: Paolo Bonzini Date: Fri, 5 Jun 2015 17:15:06 +0200 Message-Id: <1433517363-32335-6-git-send-email-pbonzini@redhat.com> In-Reply-To: <1433517363-32335-1-git-send-email-pbonzini@redhat.com> References: <1433517363-32335-1-git-send-email-pbonzini@redhat.com> Subject: [Qemu-devel] [PULL 05/62] Makefile.target: set master BUILD_DIR List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org Cc: Peter Crosthwaite , Gerd Hoffmann , Peter Crosthwaite From: Peter Crosthwaite make can be invoked in the individual build dirs to build an individual target or just a single file of a target. e.g. touch translate-all.c make -C microblazeel-softmmu translate-all.o There is however a small bug when using the pixman submodule. config-host.mak will ref BUILD_DIR for the pixman -I CFLAGS: grep BUILD_DIR config-host.mak QEMU_CFLAGS=-I$(SRC_PATH)/pixman/pixman -I$(BUILD_DIR)/pixman/pixman ... This causes a build failure as -I/pixman/pixman (BUILD_DIR=="") will not be found. BUILD_DIR is usually set by the top level Makefile. Just lazy-set it in Makefile.target to the parent directory. Granted, this will not work if the pixman submodule is not prebuilt, but it at least means you can do incremental partial builds once you have done your initial full build (or attempt) from the top level. The next step would be refactor make infrastructure to rebuild pixman on a submake like the one above. Cc: Gerd Hoffmann Signed-off-by: Peter Crosthwaite Message-Id: <1432618686-16077-1-git-send-email-crosthwaite.peter@gmail.com> Signed-off-by: Paolo Bonzini --- Makefile.target | 2 ++ 1 file changed, 2 insertions(+) diff --git a/Makefile.target b/Makefile.target index 3e861c8..ec5b92c 100644 --- a/Makefile.target +++ b/Makefile.target @@ -1,5 +1,7 @@ # -*- Mode: makefile -*- +BUILD_DIR?=$(CURDIR)/.. + include ../config-host.mak include config-target.mak include config-devices.mak -- 2.4.1