summaryrefslogtreecommitdiffstats
path: root/meta/classes/npm.bbclass
diff options
context:
space:
mode:
Diffstat (limited to 'meta/classes/npm.bbclass')
-rw-r--r--meta/classes/npm.bbclass6
1 files changed, 4 insertions, 2 deletions
diff --git a/meta/classes/npm.bbclass b/meta/classes/npm.bbclass
index 3dd2d13804..9703f4c1ec 100644
--- a/meta/classes/npm.bbclass
+++ b/meta/classes/npm.bbclass
@@ -10,7 +10,7 @@ def node_pkgname(d):
10 10
11NPMPN ?= "${@node_pkgname(d)}" 11NPMPN ?= "${@node_pkgname(d)}"
12 12
13NPM_INSTALLDIR = "${libdir}/node/${NPMPN}" 13NPM_INSTALLDIR = "${libdir}/node_modules/${NPMPN}"
14 14
15# function maps arch names to npm arch names 15# function maps arch names to npm arch names
16def npm_oe_arch_map(target_arch, d): 16def npm_oe_arch_map(target_arch, d):
@@ -55,7 +55,7 @@ npm_do_install() {
55 mkdir -p ${D}${libdir}/node_modules 55 mkdir -p ${D}${libdir}/node_modules
56 local NPM_PACKFILE=$(npm pack .) 56 local NPM_PACKFILE=$(npm pack .)
57 npm install --prefix ${D}${prefix} -g --arch=${NPM_ARCH} --target_arch=${NPM_ARCH} --production --no-registry ${NPM_PACKFILE} 57 npm install --prefix ${D}${prefix} -g --arch=${NPM_ARCH} --target_arch=${NPM_ARCH} --production --no-registry ${NPM_PACKFILE}
58 mv ${D}${libdir}/node_modules ${D}${libdir}/node 58 ln -fs node_modules ${D}${libdir}/node
59 if [ -d ${D}${prefix}/etc ] ; then 59 if [ -d ${D}${prefix}/etc ] ; then
60 # This will be empty 60 # This will be empty
61 rmdir ${D}${prefix}/etc 61 rmdir ${D}${prefix}/etc
@@ -85,6 +85,8 @@ python populate_packages_prepend () {
85} 85}
86 86
87FILES_${PN} += " \ 87FILES_${PN} += " \
88 ${bindir} \
89 ${libdir}/node \
88 ${NPM_INSTALLDIR} \ 90 ${NPM_INSTALLDIR} \
89" 91"
90 92