diff options
author | Martin Roth <martinroth@google.com> | 2016-03-16 10:39:30 -0600 |
---|---|---|
committer | Martin Roth <martinroth@google.com> | 2016-03-21 04:03:16 +0100 |
commit | c8ed34075b7785c91cfb1c8556357b2e70cf765d (patch) | |
tree | d24ee1926540ac2e9e158d74be93b11623e33610 /payloads/external/depthcharge/Makefile | |
parent | c2b50ace1b04c90c27dae8d5999c14f925b93c65 (diff) |
payloads/external: Rename Makefile.inc to Makefile
These makefiles are not included by anything, so they shouldn't be
named Makefile.inc. Also, having them all be named 'Makefile' makes
some other consolidation work I'm doing much easier.
Change-Id: I1234539ba6a0a6f47d2eb0c21de3da3607c6b8de
Signed-off-by: Martin Roth <martinroth@google.com>
Reviewed-on: https://review.coreboot.org/14130
Tested-by: build bot (Jenkins)
Reviewed-by: Stefan Reinauer <stefan.reinauer@coreboot.org>
Diffstat (limited to 'payloads/external/depthcharge/Makefile')
-rw-r--r-- | payloads/external/depthcharge/Makefile | 71 |
1 files changed, 71 insertions, 0 deletions
diff --git a/payloads/external/depthcharge/Makefile b/payloads/external/depthcharge/Makefile new file mode 100644 index 0000000000..4e766870fc --- /dev/null +++ b/payloads/external/depthcharge/Makefile @@ -0,0 +1,71 @@ +# release-R50-7978.B +STABLE_COMMIT_ID=124af94fa5599a0698e59bf3d73675eb52fc6879 + +project_name=depthcharge +project_dir=$(CURDIR)/depthcharge +project_git_repo=https://chromium.googlesource.com/chromiumos/platform/depthcharge +project_config_file=$(project_dir)/.config +output_dir=$(project_dir)/build +libpayload_dir=$(abspath $(CURDIR)/../../libpayload) +libpayload_install_dir=$(output_dir)/lp_$(BOARD) +vboot_dir=$(abspath $(CURDIR)/../../../3rdparty/vboot) + +TAG-$(DEPTHCHARGE_MASTER)=origin/master +TAG-$(DEPTHCHARGE_STABLE)=$(STABLE_COMMIT_ID) + +unexport KCONFIG_AUTOHEADER +unexport KCONFIG_AUTOCONFIG +unexport KCONFIG_DEPENDENCIES +unexport KCONFIG_SPLITCONFIG +unexport KCONFIG_TRISTATE +unexport KCONFIG_NEGATIVES +unexport src srck obj objk + +BOARD:=$(notdir $(CONFIG_MAINBOARD_DIR)) + +all: build + +$(project_dir): + echo " Cloning $(project_name) from Git" + git clone $(project_git_repo) + +fetch: $(project_dir) + cd $(project_dir); git show $(TAG-y) >/dev/null 2>&1 ; if [ $$? -ne 0 ] || \ + [ "$(TAG-y)" = "origin/master" ]; then \ + echo " Fetching new commits from the $(project_name) git repo"; \ + git fetch; fi + +checkout: fetch + echo " Checking out $(project_name) revision $(TAG-y)" + cd $(project_dir) ; git checkout master; git branch -D coreboot 2>/dev/null; git checkout -b coreboot $(TAG-y) + +$(libpayload_install_dir): $(project_dir) + test -f $(libpayload_dir)/configs/config.$(BOARD) || \ + (echo "Error: $(libpayload_dir)/configs/config.$(BOARD) is not present" && \ + false) + cp $(libpayload_dir)/configs/config.$(BOARD) $(libpayload_dir)/.config + $(MAKE) -C $(libpayload_dir) olddefconfig + $(MAKE) -C $(libpayload_dir) + $(MAKE) -C $(libpayload_dir) install DESTDIR=$(libpayload_install_dir) +# rm -f $(libpayload_dir)/.config + +config: $(libpayload_install_dir) checkout + echo " CONFIG project_name $(TAG-y)" + export VERSION=$$(cd depthcharge && \ + git describe --tags --long --dirty 2>/dev/null || \ + echo "unknown") ; \ + cd $(project_dir) && $(MAKE) BOARD=$(BOARD) LIBPAYLOAD_DIR=$(libpayload_install_dir)/libpayload \ + VB_SOURCE=$(vboot_dir) defconfig + +build: config + echo " MAKE $(project_name) $(TAG-y)" + cd $(project_dir) && $(MAKE) BOARD=$(BOARD) LIBPAYLOAD_DIR=$(libpayload_install_dir)/libpayload \ + VB_SOURCE=$(vboot_dir) PATH="$(abspath ../../../build/util/cbfstool):$$PATH" depthcharge_unified + +clean: + test -d $(output_dir) && rm -rf $(output_dir) || exit 0 + +distclean: + rm -rf $(project_dir) + +.PHONY: checkout config build clean distclean clone fetch |