From 12b641d3dfde1e24536d61060d6e4fe99cc8ae62 Mon Sep 17 00:00:00 2001 From: Iru Cai Date: Sat, 16 Apr 2016 00:54:23 +0800 Subject: coreinfo: Build libpayload in coreinfo directory When building libpayload, make the build directory and .config outside libpayload source directory so it'll not pollute the libpayload source and cause conflicts with other builds. Change-Id: Idcfbc7dbe4d52a3559229d8450c3efaafd33b93b Signed-off-by: Iru Cai Reviewed-on: https://review.coreboot.org/14389 Tested-by: build bot (Jenkins) Reviewed-by: Martin Roth --- payloads/coreinfo/Makefile | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) (limited to 'payloads/coreinfo/Makefile') diff --git a/payloads/coreinfo/Makefile b/payloads/coreinfo/Makefile index e62cdda644..d953091187 100644 --- a/payloads/coreinfo/Makefile +++ b/payloads/coreinfo/Makefile @@ -114,11 +114,12 @@ ifneq ($(strip $(HAVE_LIBPAYLOAD)),) libpayload: printf "Found Libpayload $(LIBPAYLOAD_OBJ).\n" else +LPOPTS=obj="$(CURDIR)/lpbuild" DOTCONFIG="$(CURDIR)/lp.config" libpayload: printf "Building libpayload @ $(LIBPAYLOAD_PATH).\n" - $(MAKE) -C $(LIBPAYLOAD_PATH) distclean coreinfo_obj=$(coreinfo_obj)/libptmp - $(MAKE) -C $(LIBPAYLOAD_PATH) defconfig KBUILD_DEFCONFIG=$(LIBPAYLOAD_CONFIG) - $(MAKE) -C $(LIBPAYLOAD_PATH) install DESTDIR=$(coreinfo_obj) + $(MAKE) -C $(LIBPAYLOAD_PATH) $(LPOPTS) distclean coreinfo_obj=$(coreinfo_obj)/libptmp + $(MAKE) -C $(LIBPAYLOAD_PATH) $(LPOPTS) defconfig KBUILD_DEFCONFIG=$(LIBPAYLOAD_CONFIG) + $(MAKE) -C $(LIBPAYLOAD_PATH) $(LPOPTS) install DESTDIR=$(coreinfo_obj) endif $(coreinfo_obj)/config.h: @@ -130,8 +131,8 @@ clean: rm -rf build/*.elf build/*.o .xcompile distclean: clean - rm -rf build - rm -f .config .config.old ..config.tmp .kconfig.d .tmpconfig* + rm -rf build lpbuild + rm -f *.config *.config.old ..config.tmp .kconfig.d .tmpconfig* include $(srck)/Makefile -- cgit v1.2.3