]> xenbits.xensource.com Git - xentesttools/bootstrap.git/commitdiff
Makefile: Make it possible to build a quite build.
authorKonrad Rzeszutek Wilk <konrad.wilk@oracle.com>
Sat, 8 Jun 2013 19:24:31 +0000 (15:24 -0400)
committerKonrad Rzeszutek Wilk <konrad.wilk@oracle.com>
Mon, 10 Jun 2013 14:50:38 +0000 (10:50 -0400)
V=1 will make it noisy.

Signed-off-by: Konrad Rzeszutek Wilk <konrad.wilk@oracle.com>
Makefile

index 1979e761177478961b48988aecec9193572d79f0..7fcdd67fee4dd673c3638ec789766ad3e9fcad42 100644 (file)
--- a/Makefile
+++ b/Makefile
@@ -40,6 +40,12 @@ COMPONENTS = root_image linux syslinux
 TOP= .
 include sources.mk
 
+ifeq ("$(origin V)", "command line")
+  KBUILD_VERBOSE = $(V)
+endif
+ifndef KBUILD_VERBOSE
+  KBUILD_VERBOSE = 0
+endif
 #####################################################################
 #                        exported variables
 #####################################################################
@@ -88,11 +94,19 @@ NCPUS := $(shell grep processor /proc/cpuinfo | wc -l)
 .PHONY:        linux-dist-nodep
 linux-dist-nodep: linux-config
 ifeq ($(OLDSTYLE),1)
+ifeq ($(KBUILD_VERBOSE),1)
        $(MAKE) -j$$(($(NCPUS) * 2)) -C $(LINUX_SRC) O=$(LINUX_DST) vmlinuz
+else
+       $(MAKE) -j$$(($(NCPUS) * 2)) -C $(LINUX_SRC) O=$(LINUX_DST) vmlinuz 1>/dev/null
+endif
        $(INSTALL_DIR) dist/common/
        $(INSTALL_DATA) $(LINUX_DST)/arch/$(ARCH)/boot/vmlinuz dist/common/vmlinuz
 else
+ifeq ($(KBUILD_VERBOSE),1)
        $(MAKE) -j$$(($(NCPUS) * 2)) -C $(LINUX_SRC) O=$(LINUX_DST) bzImage
+else
+       $(MAKE) -j$$(($(NCPUS) * 2)) -C $(LINUX_SRC) O=$(LINUX_DST) bzImage 1>/dev/null
+endif
        $(INSTALL_DIR) dist/common/
        $(INSTALL_DATA) $(LINUX_DST)/arch/$(ARCH)/boot/bzImage dist/common/vmlinuz
 endif
@@ -162,7 +176,11 @@ xen-dist-nodep:
 ifeq ($(ARCH),i386)
        touch xen/xen/xen.gz
 else
+ifeq ($(KBUILD_VERBOSE),1)
        $(MAKE) -C xen xen -j$$(($(NCPUS) * 2))
+else
+       $(MAKE) -C xen xen -j$$(($(NCPUS) * 2)) 1>/dev/null
+endif
 endif
 
        $(INSTALL_DIR) dist/common/
@@ -176,8 +194,11 @@ IOEMU_DIR = ioemu-remote
 .PHONY: xen-tools
 xen-tools:
 #      $(MAKE) -C xen dist-misc -j$$(($(NCPUS) * 2))
-
+ifeq ($(KBUILD_VERBOSE),1)
        $(MAKE) -C xen IOEMU_CONFIGURE_CROSS="--disable-curses --disable-slirp --disable-opengl --disable-sdl --disable-kvm --disable-vnc-tls" tools -j$$(($(NCPUS) * 2))
+else
+       $(MAKE) -C xen IOEMU_CONFIGURE_CROSS="--disable-curses --disable-slirp --disable-opengl --disable-sdl --disable-kvm --disable-vnc-tls" tools -j$$(($(NCPUS) * 2)) 1>/dev/null
+endif
 
 ifeq ($(NOXEN),1)
 .PHONY: xen-dist
@@ -209,7 +230,11 @@ DOM0_DEP_LIST = linux-modules
 
 .PHONY: root_image-dist-nodep
 root_image-dist-nodep:  $(LINUX_SRC)/usr/gen_init_cpio
+ifeq ($(KBUILD_VERBOSE),1)
        $(MAKE)  -C root_image
+else
+       $(MAKE)  -C root_image 1>/dev/null
+endif
        $(INSTALL_DIR) dist/common/
        $(INSTALL_DATA) root_image/dist/common/initramfs.cpio.gz dist/common/