mirror of
https://git.yoctoproject.org/poky
synced 2026-04-04 14:02:22 +02:00
devtool: handle . in recipe name
Names such as glib-2.0 are valid (and used) recipe names, so we need to support them. Fixes [YOCTO #7643]. (From OE-Core master rev: b9fd8d4d4dfae72de2e81e9b14de072e12cecdcf) (From OE-Core rev: 36df1bb9bb3c92d096118b74fdf11a243be3f7d5) Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
This commit is contained in:
committed by
Richard Purdie
parent
d768a80391
commit
2bc3328b8b
@@ -269,8 +269,8 @@ def get_recipe_patches(d):
|
||||
def validate_pn(pn):
|
||||
"""Perform validation on a recipe name (PN) for a new recipe."""
|
||||
reserved_names = ['forcevariable', 'append', 'prepend', 'remove']
|
||||
if not re.match('[0-9a-z-]+', pn):
|
||||
return 'Recipe name "%s" is invalid: only characters 0-9, a-z and - are allowed' % pn
|
||||
if not re.match('[0-9a-z-.]+', pn):
|
||||
return 'Recipe name "%s" is invalid: only characters 0-9, a-z, - and . are allowed' % pn
|
||||
elif pn in reserved_names:
|
||||
return 'Recipe name "%s" is invalid: is a reserved keyword' % pn
|
||||
elif pn.startswith('pn-'):
|
||||
|
||||
@@ -101,7 +101,7 @@ def read_workspace():
|
||||
_create_workspace(config.workspace_path, config, basepath)
|
||||
|
||||
logger.debug('Reading workspace in %s' % config.workspace_path)
|
||||
externalsrc_re = re.compile(r'^EXTERNALSRC(_pn-[a-zA-Z0-9-]*)? =.*$')
|
||||
externalsrc_re = re.compile(r'^EXTERNALSRC(_pn-[^ =]+)? =.*$')
|
||||
for fn in glob.glob(os.path.join(config.workspace_path, 'appends', '*.bbappend')):
|
||||
pn = os.path.splitext(os.path.basename(fn))[0].split('_')[0]
|
||||
with open(fn, 'r') as f:
|
||||
|
||||
Reference in New Issue
Block a user