Makefile: use -C parameter for recursive invocation

Instead of changing directories with "cd" command use the
-C parameter to change directory.

Signed-off-by: Miguel Bernal Marin <miguel.bernal.marin@linux.intel.com>
This commit is contained in:
Miguel Bernal Marin 2018-05-16 13:21:26 -05:00 committed by lijinxia
parent a6ff3a9bdc
commit f7a93d8f33
1 changed files with 7 additions and 12 deletions

View File

@ -13,23 +13,18 @@ TOOLS_OUT := $(ROOT_OUT)/tools
all: hypervisor devicemodel tools
hypervisor:
cd $(T)/hypervisor; \
make HV_OBJDIR=$(HV_OUT) PLATFORM=$(PLAT) RELEASE=$(RELEASE) clean; \
make HV_OBJDIR=$(HV_OUT) PLATFORM=$(PLAT) RELEASE=$(RELEASE)
make -C $(T)/hypervisor HV_OBJDIR=$(HV_OUT) PLATFORM=$(PLAT) RELEASE=$(RELEASE) clean; \
make -C $(T)/hypervisor HV_OBJDIR=$(HV_OUT) PLATFORM=$(PLAT) RELEASE=$(RELEASE)
devicemodel:
cd $(T)/devicemodel; \
make DM_OBJDIR=$(DM_OUT) clean; \
make DM_OBJDIR=$(DM_OUT)
make -C $(T)/devicemodel DM_OBJDIR=$(DM_OUT) clean; \
make -C $(T)/devicemodel DM_OBJDIR=$(DM_OUT)
tools:
mkdir -p $(TOOLS_OUT)
cd $(T)/tools/acrnlog; \
make OUT_DIR=$(TOOLS_OUT);
cd $(T)/tools/acrn-manager; \
make OUT_DIR=$(TOOLS_OUT);
cd $(T)/tools/acrntrace; \
make OUT_DIR=$(TOOLS_OUT);
make -C $(T)/tools/acrnlog OUT_DIR=$(TOOLS_OUT);
make -C $(T)/tools/acrn-manager OUT_DIR=$(TOOLS_OUT);
make -C $(T)/tools/acrntrace OUT_DIR=$(TOOLS_OUT);
.PHONY: clean
clean: