summaryrefslogtreecommitdiffstats
path: root/Makefile
diff options
context:
space:
mode:
authorAlexandru Avadanii <Alexandru.Avadanii@enea.com>2017-08-29 22:44:47 +0200
committerAlexandru Avadanii <Alexandru.Avadanii@enea.com>2017-08-29 22:48:37 +0200
commite068bba6557d2f26f2e143e67167f848bb87b2a9 (patch)
treefb54e3dc92db678ab0948f05c38d912ce863dbe7 /Makefile
parentb2e6a3583baf97124dfbfd62026c57f114968efd (diff)
Makefile: Implement `make patches-copyright`
JIRA: ARMBAND-301 Change-Id: Ib2fe43d3a4be627831768419486226ed2484ddae Signed-off-by: Alexandru Avadanii <Alexandru.Avadanii@enea.com>
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile9
1 files changed, 9 insertions, 0 deletions
diff --git a/Makefile b/Makefile
index 6d82466e..43edd22d 100644
--- a/Makefile
+++ b/Makefile
@@ -126,4 +126,13 @@ fuel-patches-import: .submodules-patched fuel-patches-clean
fuel-patches-clean:
$(MAKE) -e -C ${F_PATCH_DIR} clean
+# Add copyright header to patch files if not already present
+.PHONY: patches-copyright
+patches-copyright:
+ grep -e "Copyright (c)" -L ${A_PATCHES} | while read p_file; do \
+ ptmp=`mktemp` && \
+ cat armband-patch-copyright.template $$p_file > $$ptmp && \
+ mv $$ptmp $$p_file; \
+ done
+
# TODO: Bring back clean/debug/build after Fuel@OPNFV implements them for MCP