2017-02-28 105 views
0

我想在基於linux的arm處理器上安裝節點包「sqlite3」。當我嘗試安裝軟件包時出現錯誤。但是,如果我嘗試在Ubuntu上安裝相同的軟件包,它會通過。npm在手臂上安裝sqlite3錯誤

我在arm處理器上使用Linux Kernel 3.14.52-v2.6b2 + g7c83cef。

我用於sqlite3安裝的命令是npm install sqlite3。我確實嘗試了this鏈接,但沒用。

我得到一個不同的錯誤

[email protected]:~# npm install sqlite3 
-\|-\ 
> [email protected] install /home/root/node_modules/sqlite3 
> node-pre-gyp install --fallback-to-build 
node-pre-gyp ERR! Tried to download(undefined): https://mapbox-node-binary.s3.amazonaws.com/sqlite3/v3.1.8/node-v14-linux-arm.tar.gz 
node-pre-gyp ERR! Pre-built binaries not found for [email protected] and [email protected] (node-v14 ABI) (falling back to source compile with node-gyp 
make: Entering directory '/home/root/node_modules/sqlite3/build' 
    ACTION deps_sqlite3_gyp_action_before_build_target_unpack_sqlite_dep Release/obj/gen/sqlite-autoconf-3150000/sqlite3.c 
    TOUCH Release/obj.target/deps/action_before_build.stamp 
    CC(target) Release/obj.target/sqlite3/gen/sqlite-autoconf-3150000/sqlite3.o 
make: cc: Command not found 
    deps/sqlite3.target.mk:117: recipe for target 'Release/obj.target/sqlite3/gen/sqlite-autoconf-3150000/sqlite3.o' failed 
make: *** [Release/obj.target/sqlite3/gen/sqlite-autoconf-3150000/sqlite3.o] Error 127 
make: Leaving directory '/home/root/node_modules/sqlite3/build' 
gyp ERR! build error 
gyp ERR! stack Error: `make` failed with exit code: 2 
gyp ERR! stack  at ChildProcess.onExit (/usr/lib/node_modules/npm/node_modules/node-gyp/lib/build.js:269:23) 
gyp ERR! stack  at ChildProcess.emit (events.js:110:17) 
gyp ERR! stack  at Process.ChildProcess._handle.onexit (child_process.js:1074:12) 
gyp ERR! System Linux 3.14.52-v2.6b2+g7c83cef 
gyp ERR! command "/usr/bin/node" "/usr/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "build" "--fallback-to-build" "--module=/h" 
gyp ERR! cwd /home/root/node_modules/sqlite3 
gyp ERR! node -v v0.12.7 
gyp ERR! node-gyp -v v2.0.1 
gyp ERR! not ok 
node-pre-gyp ERR! build error 
node-pre-gyp ERR! stack Error: Failed to execute '/usr/bin/node /usr/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js build --fallb) 
node-pre-gyp ERR! stack  at ChildProcess.<anonymous> (/home/root/node_modules/sqlite3/node_modules/node-pre-gyp/lib/util/compile.js:83:29) 
node-pre-gyp ERR! stack  at ChildProcess.emit (events.js:110:17) 
node-pre-gyp ERR! stack  at maybeClose (child_process.js:1015:16) 
node-pre-gyp ERR! stack  at Process.ChildProcess._handle.onexit (child_process.js:1087:5) 
node-pre-gyp ERR! System Linux 3.14.52-v2.6b2+g7c83cef 
node-pre-gyp ERR! command "node" "/home/root/node_modules/sqlite3/node_modules/.bin/node-pre-gyp" "install" "--fallback-to-build" 
node-pre-gyp ERR! cwd /home/root/node_modules/sqlite3 
node-pre-gyp ERR! node -v v0.12.7 
node-pre-gyp ERR! node-pre-gyp -v v0.6.31 
node-pre-gyp ERR! not ok 
Failed to execute '/usr/bin/node /usr/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js build --fallback-to-build --module=/home/roo) 
npm ERR! Linux 3.14.52-v2.6b2+g7c83cef 
npm ERR! argv "node" "/usr/bin/npm" "install" "sqlite3" 
npm ERR! node v0.12.7 
npm ERR! npm v2.11.3 
npm ERR! code ELIFECYCLE 

npm ERR! [email protected] install: `node-pre-gyp install --fallback-to-build` 
npm ERR! Exit status 1 
npm ERR! 
npm ERR! Failed at the [email protected] install script 'node-pre-gyp install --fallback-to-build'. 
npm ERR! This is most likely a problem with the sqlite3 package, 
npm ERR! not with npm itself. 
npm ERR! Tell the author that this fails on your system: 
npm ERR!  node-pre-gyp install --fallback-to-build 
npm ERR! You can get their info via: 
npm ERR!  npm owner ls sqlite3 
npm ERR! There is likely additional logging output above. 

npm ERR! Please include the following file with any support request: 
npm ERR!  /home/root/npm-debug.log 
[email protected]:~# 

我裝蟒蛇編譯,蟒蛇模塊,現在GCC照顧cc命令,但沒有什麼工作的。有沒有人遇到過這個問題?

回答

0

這可能是因爲您的基於ARM處理器沒有與操作系統捆綁的C編譯器(GCC通常用於Linux)...

調試日誌告訴包上編譯本地源失敗。

我不能告訴你這是肯定的原因,但你應該嘗試這種方式!