MediaTek-Labs / linkit-smart-7688-feed

190 stars 152 forks source link

node-serialport make error #5

Closed ironshi closed 8 years ago

ironshi commented 8 years ago

Linux distribution : Ubuntu 14.04.1(x86_64) Linux version : 3.16.0-45-generic

I have a issue in openwrt make process , it seem to node-serialport make error issue.

serialport@1.4.6 install /root/workspace/openwrt/build_dir/target-mipsel_24kec+dsp_uClibc-0.9.33.2/node-serialport-1.4.6/ipkg-install/usr/lib/node_modules/serialport node-pre-gyp reinstall --build-from-source --target_arch=${npm_config_arch}

gyp ERR! configure error gyp ERR! stack Error: EACCES, mkdir '/root/workspace/openwrt/build_dir/target-mipsel_24kec+dsp_uClibc-0.9.33.2/node-serialport-1.4.6/ipkg-install/usr/lib/node_modules/serialport/build' gyp ERR! System Linux 3.16.0-45-generic gyp ERR! command "nodejs" "/usr/bin/node-gyp" "configure" "--build-from-source" "--target_arch=mipsel" "--module=/root/workspace/openwrt/build_dir/target-mipsel_24kec+dsp_uClibc-0.9.33.2/node-serialport-1.4.6/ipkg-install/usr/lib/node_modules/serialport/build/serialport/v1.4.6/Release/node-v11-linux-mipsel/serialport.node" "--module_name=serialport" "--module_path=/root/workspace/openwrt/build_dir/target-mipsel_24kec+dsp_uClibc-0.9.33.2/node-serialport-1.4.6/ipkg-install/usr/lib/node_modules/serialport/build/serialport/v1.4.6/Release/node-v11-linux-mipsel" "--nodedir=/root/workspace/openwrt/build_dir/target-mipsel_24kec+dsp_uClibc-0.9.33.2/node-v0.12.7/" gyp ERR! cwd /root/workspace/openwrt/build_dir/target-mipsel_24kec+dsp_uClibc-0.9.33.2/node-serialport-1.4.6/ipkg-install/usr/lib/node_modules/serialport gyp ERR! node -v v0.10.25 gyp ERR! node-gyp -v v0.10.10 gyp ERR! not ok node-pre-gyp ERR! build error node-pre-gyp ERR! stack Error: Failed to execute 'node-gyp configure --build-from-source --target_arch=mipsel --module=/root/workspace/openwrt/build_dir/target-mipsel_24kec+dsp_uClibc-0.9.33.2/node-serialport-1.4.6/ipkg-install/usr/lib/node_modules/serialport/build/serialport/v1.4.6/Release/node-v11-linux-mipsel/serialport.node --module_name=serialport --module_path=/root/workspace/openwrt/build_dir/target-mipsel_24kec+dsp_uClibc-0.9.33.2/node-serialport-1.4.6/ipkg-install/usr/lib/node_modules/serialport/build/serialport/v1.4.6/Release/node-v11-linux-mipsel --nodedir=/root/workspace/openwrt/build_dir/target-mipsel_24kec+dsp_uClibc-0.9.33.2/node-v0.12.7/' (1) node-pre-gyp ERR! stack at ChildProcess. (/usr/local/lib/node_modules/node-pre-gyp/lib/util/compile.js:83:29) node-pre-gyp ERR! stack at ChildProcess.EventEmitter.emit (events.js:98:17) node-pre-gyp ERR! stack at maybeClose (child_process.js:743:16) node-pre-gyp ERR! stack at Process.ChildProcess._handle.onexit (child_process.js:810:5) node-pre-gyp ERR! System Linux 3.16.0-45-generic node-pre-gyp ERR! command "node" "/usr/local/bin/node-pre-gyp" "reinstall" "--build-from-source" "--target_arch=mipsel" node-pre-gyp ERR! cwd /root/workspace/openwrt/build_dir/target-mipsel_24kec+dsp_uClibc-0.9.33.2/node-serialport-1.4.6/ipkg-install/usr/lib/node_modules/serialport node-pre-gyp ERR! node -v v0.10.25 node-pre-gyp ERR! node-pre-gyp -v v0.6.18 node-pre-gyp ERR! not ok Failed to execute 'node-gyp configure --build-from-source --target_arch=mipsel --module=/root/workspace/openwrt/build_dir/target-mipsel_24kec+dsp_uClibc-0.9.33.2/node-serialport-1.4.6/ipkg-install/usr/lib/node_modules/serialport/build/serialport/v1.4.6/Release/node-v11-linux-mipsel/serialport.node --module_name=serialport --module_path=/root/workspace/openwrt/build_dir/target-mipsel_24kec+dsp_uClibc-0.9.33.2/node-serialport-1.4.6/ipkg-install/usr/lib/node_modules/serialport/build/serialport/v1.4.6/Release/node-v11-linux-mipsel --nodedir=/root/workspace/openwrt/build_dir/target-mipsel_24kec+dsp_uClibc-0.9.33.2/node-v0.12.7/' (1) npm ERR! Linux 3.16.0-45-generic npm ERR! argv "/root/workspace/openwrt/staging_dir/host/bin/node" "/root/workspace/openwrt/staging_dir/host/bin/npm" "install" "-g" "/root/workspace/openwrt/build_dir/target-mipsel_24kec+dsp_uClibc-0.9.33.2/node-serialport-1.4.6" npm ERR! node v0.12.7 npm ERR! npm v2.11.3 npm ERR! code ELIFECYCLE

npm ERR! serialport@1.4.6 install: node-pre-gyp reinstall --build-from-source --target_arch=${npm_config_arch} npm ERR! Exit status 1 npm ERR! npm ERR! Failed at the serialport@1.4.6 install script 'node-pre-gyp reinstall --build-from-source --target_arch=${npm_config_arch}'. npm ERR! This is most likely a problem with the serialport package, npm ERR! not with npm itself. npm ERR! Tell the author that this fails on your system: npm ERR! node-pre-gyp reinstall --build-from-source --target_arch=${npm_config_arch} npm ERR! You can get their info via: npm ERR! npm owner ls serialport npm ERR! There is likely additional logging output above.

npm ERR! Please include the following file with any support request: npm ERR! /root/workspace/openwrt/feeds/packages/lang/node-serialport/npm-debug.log make[3]: * [/root/workspace/openwrt/build_dir/target-mipsel_24kec+dsp_uClibc-0.9.33.2/node-serialport-1.4.6/.built] Error 1 make[3]: Leaving directory /root/workspace/openwrt/feeds/packages/lang/node-serialport' make[2]: *** [package/feeds/packages/node-serialport/compile] Error 2 make[2]: Leaving directory/root/workspace/openwrt' make[1]: *\ [/root/workspace/openwrt/staging_dir/target-mipsel_24kec+dsp_uClibc-0.9.33.2/stamp/.package_compile] Error 2 make[1]: Leaving directory `/root/workspace/openwrt' make: * [world] Error 2

ironshi commented 8 years ago

I found the reason for this issue. Because I used root account login......