geeeeeeeeek / electronic-wechat

:speech_balloon: A better WeChat on macOS and Linux. Built with Electron by Zhongyi Tong.
MIT License
13.93k stars 2.72k forks source link

npm run build:linux 总出错 #597

Open shpx opened 6 years ago

shpx commented 6 years ago

Description

~/electronic-wechat/scripts$ npm run build:linux

electronic-wechat@2.0.0 build:linux /home/tom/electronic-wechat ./scripts/build.sh linux x64

\033[0;31mError\033[0m: you need to npm install electron-packager. Aborting.

npm ERR! Linux 4.10.0-40-generic npm ERR! argv "/usr/bin/nodejs" "/usr/bin/npm" "run" "build:linux" npm ERR! node v4.2.6 npm ERR! npm v3.5.2 npm ERR! code ELIFECYCLE npm ERR! electronic-wechat@2.0.0 build:linux: ./scripts/build.sh linux x64 npm ERR! Exit status 1 npm ERR! npm ERR! Failed at the electronic-wechat@2.0.0 build:linux script './scripts/build.sh linux x64'. npm ERR! Make sure you have the latest version of node.js and npm installed. npm ERR! If you do, this is most likely a problem with the electronic-wechat package, npm ERR! not with npm itself. npm ERR! Tell the author that this fails on your system: npm ERR! ./scripts/build.sh linux x64 npm ERR! You can get information on how to open an issue for this project with: npm ERR! npm bugs electronic-wechat npm ERR! Or if that isn't available, you can get their info via: npm ERR! npm owner ls electronic-wechat npm ERR! There is likely additional logging output above.

npm ERR! Please include the following file with any support request: npm ERR! /home/tom/electronic-wechat/scripts/npm-debug.log

Specifications

<Stack trace here>
rocka commented 6 years ago

Error: you need to npm install electron-packager. Aborting.

shpx commented 6 years ago

npm run build:linux

electronic-wechat@2.0.0 build:linux /home/tom/electronic-wechat ./scripts/build.sh linux x64

Start packaging for linux x64. /usr/bin/env: "node": 没有那个文件或目录

rocka commented 6 years ago

怎么会找不到 node ... 你是怎么安装 node 的呢

shpx commented 6 years ago

apt-get install node.js

shpx commented 6 years ago

成功了,谢谢指导

rocka commented 6 years ago
apt-get install nodejs-legacy

或者

ln -s /usr/bin/nodejs /usr/bin/node
ghost commented 6 years ago

@shpx 请问是怎么解决呢?

shpx commented 6 years ago

当初好像是缺少一个nodejs,然后解决方法好像是http://blog.csdn.net/ererfei/article/details/50161825