summaryrefslogtreecommitdiffstats
path: root/meta/lib/oe
diff options
context:
space:
mode:
authorBrendan Le Foll <brendan.le.foll@intel.com>2016-04-12 10:58:39 +0100
committerRichard Purdie <richard.purdie@linuxfoundation.org>2016-04-14 10:58:27 +0100
commitfea932c79c8201e3e7649f4443874ea540e33461 (patch)
treed77c13cf365d5baf6eb86c66c3bc936a86e0eae2 /meta/lib/oe
parent080d1a313e4982dd05846b375ebf936c46934d80 (diff)
downloadopenembedded-core-fea932c79c8201e3e7649f4443874ea540e33461.tar.gz
openembedded-core-fea932c79c8201e3e7649f4443874ea540e33461.tar.bz2
openembedded-core-fea932c79c8201e3e7649f4443874ea540e33461.zip
npm.bbclass: Stop packagenames containing underscores from being generated
Package names cannot contain underscores yet some npm modules use them as part of the name, replace them with hyphens in the package name. Signed-off-by: Brendan Le Foll <brendan.le.foll@intel.com> Signed-off-by: Ross Burton <ross.burton@intel.com>
Diffstat (limited to 'meta/lib/oe')
-rw-r--r--meta/lib/oe/package.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/meta/lib/oe/package.py b/meta/lib/oe/package.py
index dea443d658..2887689541 100644
--- a/meta/lib/oe/package.py
+++ b/meta/lib/oe/package.py
@@ -143,7 +143,7 @@ def npm_split_package_dirs(pkgdir):
if pathitem == 'node_modules':
continue
pkgitems.append(pathitem)
- pkgname = '-'.join(pkgitems)
+ pkgname = '-'.join(pkgitems).replace('_', '-')
pkgfile = os.path.join(root, dn, 'package.json')
data = None
if os.path.exists(pkgfile):