Makefile: introduce check-package target
PATCH 1/1 Makefile: introduce check-package target
The snippet of code that runs a check-package on all .mk/.hash/Config.in files is currently only available within .gitlab-ci.yml, and isn't immediately and easily usable by Buildroot users. In order to simplify this, this commit introduces a top-level "check-package" make target that implements the same logic. The .gitlab-ci.yml file is changed to use "make check-package".
Since this target is oriented towards Buildroot developers, we intentionally do not clutter the already noisy "make help" text with this additional make target.
---
I often found myself copy/pasting this find command line from .gitlab-ci.yml to my shell, and got tired of doing this, hence this patch.
--- .gitlab-ci.yml | 3 +-- Makefile | 4 ++++ 2 files changed, 5 insertions(+), 2 deletions(-)
.gitlab-ci.yml +1 -2
@@ -43,8 +43,7 @@ check-flake8: check-package: script: - - find . -type f \( -name '*.mk' -o -name '*.hash' -o -name 'Config.*' \) - -exec ./utils/check-package {} + + - make check-package .defconfig: &defconfig # Running the defconfigs for every push is too much, so limit to
Makefile +4 -0
@@ -1125,6 +1125,10 @@ release: print-version: @echo $(BR2_VERSION_FULL) +check-package: + find $(TOPDIR) -type f \( -name '*.mk' -o -name '*.hash' -o -name 'Config.*' \) \ + -exec ./utils/check-package {} + + .PHONY: .gitlab-ci.yml .gitlab-ci.yml: .gitlab-ci.yml.in cp $< $@
Signature · 1 line
2.14.4
PATCH 1/1 Makefile: introduce check-package target
Hello,
Very handy make target!
On Fri, Aug 10, 2018 at 06:51 PM, Thomas Petazzoni wrote:
[snip]
Quoted 4 lines
--- .gitlab-ci.yml | 3 +-- Makefile | 4 ++++ 2 files changed, 5 insertions(+), 2 deletions(-)
You forgot to change .gitlab-ci.yml.in
[snip]
Makefile release: · line 1128
Quoted 6 lines
+++ b/Makefile
Makefile +1
-0@@ -1125,6 +1125,10 @@ release: print-version: @echo $(BR2_VERSION_FULL) +check-package:
Shouldn't it be added to noconfig_targets?
Regards,
Ricardo
PATCH 1/1 Makefile: introduce check-package target
Hello Ricardo,
Quoted 11 lines · Ricardo Martincoski
On Fri, Aug 10, 2018 at 06:51 PM, Thomas Petazzoni wrote:
[snip]
Quoted 4 lines
--- .gitlab-ci.yml | 3 +-- Makefile | 4 ++++ 2 files changed, 5 insertions(+), 2 deletions(-)You forgot to change .gitlab-ci.yml.in
[snip]
Quoted 8 lines
Makefile release: · line 1128
Quoted 6 lines
+++ b/Makefile
Makefile +1
-0@@ -1125,6 +1125,10 @@ release: print-version: @echo $(BR2_VERSION_FULL) +check-package:Shouldn't it be added to
noconfig_targets?
Thanks for your review! I've fixed those issues and sent a v2.
Best regards,
Thomas
Signature · 3 lines
Thomas Petazzoni, CTO, Bootlin (formerly Free Electrons) Embedded Linux and Kernel engineering https://bootlin.com