Angel Pons submitted this change.

View Change


Approvals: build bot (Jenkins): Verified Angel Pons: Looks good to me, approved Edward O'Callaghan: Looks good to me, approved Anastasia Klimchuk: Looks good to me, approved
Makefile: Don't install git hooks automatically

These specific git hooks are only needed when someone wants to push a
patch to upstream and so it's not needed to run it in every make call.
Beside that, we also don't know the environment in which this is
executed and it might not be wanted.

Thus, add a new make target `gitconfig` and move the install command to
it. It can be used by running `make gitconfig`.

Signed-off-by: Felix Singer <felixsinger@posteo.net>
Change-Id: Ib83568c7ff149a8ec34ad7e92720c36a89def7bd
Reviewed-on: https://review.coreboot.org/c/flashrom/+/68647
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Angel Pons <th3fanbus@gmail.com>
Reviewed-by: Edward O'Callaghan <quasisec@chromium.org>
Reviewed-by: Anastasia Klimchuk <aklm@chromium.org>
---
M Makefile
1 file changed, 26 insertions(+), 3 deletions(-)

diff --git a/Makefile b/Makefile
index a8df91f..425b58c 100644
--- a/Makefile
+++ b/Makefile
@@ -408,9 +408,6 @@
# No spaces in release names unless set explicitly
RELEASENAME ?= $(shell echo "$(VERSION)" | sed -e 's/ /_/')

-# If a VCS is found then try to install hooks.
-$(shell ./util/getrevision.sh -c 2>/dev/null && ./util/git-hooks/install.sh)
-
###############################################################################
# Default settings of CONFIG_* variables.

@@ -1040,6 +1037,9 @@
libpayload: clean
make CC="CC=i386-elf-gcc lpgcc" AR=i386-elf-ar RANLIB=i386-elf-ranlib

+gitconfig:
+ ./util/getrevision.sh -c 2>/dev/null && ./util/git-hooks/install.sh
+
.PHONY: all install clean distclean config _export export tarball libpayload

# Disable implicit suffixes and built-in rules (for performance and profit)

To view, visit change 68647. To unsubscribe, or for help writing mail filters, visit settings.

Gerrit-Project: flashrom
Gerrit-Branch: master
Gerrit-Change-Id: Ib83568c7ff149a8ec34ad7e92720c36a89def7bd
Gerrit-Change-Number: 68647
Gerrit-PatchSet: 6
Gerrit-Owner: Felix Singer <felixsinger@posteo.net>
Gerrit-Reviewer: Anastasia Klimchuk <aklm@chromium.org>
Gerrit-Reviewer: Angel Pons <th3fanbus@gmail.com>
Gerrit-Reviewer: Edward O'Callaghan <quasisec@chromium.org>
Gerrit-Reviewer: Nico Huber <nico.h@gmx.de>
Gerrit-Reviewer: Thomas Heijligen <src@posteo.de>
Gerrit-Reviewer: build bot (Jenkins) <no-reply@coreboot.org>
Gerrit-MessageType: merged