aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGravatar Ricardo Martincoski <ricardo.martincoski@gmail.com>2018-11-04 02:12:08 -0200
committerGravatar Arnout Vandecappelle (Essensium/Mind) <arnout@mind.be>2019-08-03 17:17:29 +0200
commit75d6c2ba96bcfd796210f7ad73f71543996c4a04 (patch)
treef0371e6691fff796596cd26abc779f1ee2c8cf85
parent4323fbaf8d203da5782d042d6f2fd399300ca03a (diff)
downloadbuildroot-75d6c2ba96bcfd796210f7ad73f71543996c4a04.tar.gz
buildroot-75d6c2ba96bcfd796210f7ad73f71543996c4a04.tar.bz2
check-package: ignore external.mk
The external.mk file in a br2-external usually contains raw makefile targets. This file is common code and not a package recipe so it should not be tested against the code-style of a package .mk file. When using this script to check files in a br2-external tree, usually the user is responsible for not passing files that check-package do not understand. But external.mk is special because it is part of the br2-external structure, so it is likely someone expects it to be checkable by an in-tree script. Instead of adding another blob to the manual, just ignore this file. Only do that when a br2-external is being tested (so with option -b passed to the script) and also check that it is on the root path of the br2-external to allow someone to have a package called external. Reported on bug #11271. Reported-by: Vitaliy Lotorev <lotorev@gmail.com> Signed-off-by: Ricardo Martincoski <ricardo.martincoski@gmail.com> Cc: Thomas Petazzoni <thomas.petazzoni@bootlin.com> [Arnout: wrap at 80 columns] Signed-off-by: Arnout Vandecappelle (Essensium/Mind) <arnout@mind.be>
-rwxr-xr-xutils/check-package4
1 files changed, 4 insertions, 0 deletions
diff --git a/utils/check-package b/utils/check-package
index f09aaeea03..52317e02f4 100755
--- a/utils/check-package
+++ b/utils/check-package
@@ -73,6 +73,10 @@ def get_lib_from_filename(fname):
return None
if DO_NOT_CHECK_INTREE.match(fname):
return None
+ else:
+ if os.path.basename(fname) == "external.mk" and \
+ os.path.exists(fname[:-2] + "desc"):
+ return None
if CONFIG_IN_FILENAME.search(fname):
return checkpackagelib.lib_config
if fname.endswith(".hash"):