diff options
author | Vyacheslav Yurkov <uvv.mail@gmail.com> | 2021-01-28 19:42:46 +0100 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2021-01-30 10:38:48 +0000 |
commit | d21f50ecf8e8683a92b7d234fa8225c2c1470595 (patch) | |
tree | a49f60edd3bb2466c9a60eb00ec85033edef00ac /meta/classes/npm.bbclass | |
parent | d5d06fa31c81a9e0460edada18e6d3dbecd3d94a (diff) | |
download | openembedded-core-contrib-d21f50ecf8e8683a92b7d234fa8225c2c1470595.tar.gz |
npm.bbclass: use python3 for npm config
python2-native executable is not available in sysroot anymore, which
causes compilation of some nodejs modules to fail. Switch to python3 as a
default python version.
Signed-off-by: Vyacheslav Yurkov <uvv.mail@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/classes/npm.bbclass')
-rw-r--r-- | meta/classes/npm.bbclass | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/meta/classes/npm.bbclass b/meta/classes/npm.bbclass index d3dd1a9ab8..79f55febcc 100644 --- a/meta/classes/npm.bbclass +++ b/meta/classes/npm.bbclass @@ -17,6 +17,8 @@ # NPM_INSTALL_DEV: # Set to 1 to also install devDependencies. +inherit python3native + DEPENDS_prepend = "nodejs-native " RDEPENDS_${PN}_prepend = "nodejs " @@ -248,9 +250,7 @@ python npm_do_compile() { sysroot = d.getVar("RECIPE_SYSROOT_NATIVE") nodedir = os.path.join(sysroot, d.getVar("prefix_native").strip("/")) configs.append(("nodedir", nodedir)) - bindir = os.path.join(sysroot, d.getVar("bindir_native").strip("/")) - pythondir = os.path.join(bindir, "python-native", "python") - configs.append(("python", pythondir)) + configs.append(("python", d.getVar("PYTHON"))) # Add node-pre-gyp configuration args.append(("target_arch", d.getVar("NPM_ARCH"))) |