From: Paul Eggleton Date: Thu, 19 Nov 2015 01:15:55 +0000 (+1300) Subject: lib/oe/recipeutils: check in validate_pn() for names instead of filenames X-Git-Tag: 2016-4~2149 X-Git-Url: https://code.ossystems.io/gitweb?a=commitdiff_plain;h=a4c6af737811adb2bca87e3896f8710738dd255e;p=openembedded-core.git lib/oe/recipeutils: check in validate_pn() for names instead of filenames Ensure that the user specifies just the name portion instead of a file name with extension. (We can't just look for . since there are recipe names such as "glib-2.0" that legitimately contain .). Signed-off-by: Paul Eggleton Signed-off-by: Ross Burton --- diff --git a/meta/lib/oe/recipeutils.py b/meta/lib/oe/recipeutils.py index 119a68821b..8918facb5b 100644 --- a/meta/lib/oe/recipeutils.py +++ b/meta/lib/oe/recipeutils.py @@ -398,6 +398,8 @@ def validate_pn(pn): return 'Recipe name "%s" is invalid: is a reserved keyword' % pn elif pn.startswith('pn-'): return 'Recipe name "%s" is invalid: names starting with "pn-" are reserved' % pn + elif pn.endswith(('.bb', '.bbappend', '.bbclass', '.inc', '.conf')): + return 'Recipe name "%s" is invalid: should be just a name, not a file name' % pn return ''