首页 > 解决方案 > npm 在树莓派 3 上安装 sqlite3

问题描述

我尝试使用以下命令在 rasberry pi 3 上安装 sqlite3:

 $ npm install sqlite3 --save

但不幸的是我有以下错误:

  npm WARN read-shrinkwrap This version of npm is compatible with lockfileVersion@1, but package-lock.json was generated for lockfileVersion@2. I'll try to do my best with it!
npm WARN deprecated node-pre-gyp@0.11.0: Please upgrade to @mapbox/node-pre-gyp: the non-scoped node-pre-gyp package is deprecated and only the @mapbox scoped package will recieve updates in the future

> sqlite3@4.2.0 install /home/pi/git/crypto-player/node_modules/sqlite3
> node-pre-gyp install --fallback-to-build

sh: 1: node-pre-gyp: not found
npm WARN crypto-player No description
npm WARN crypto-player No repository field.
npm WARN crypto-player No license field.

npm ERR! code ELIFECYCLE
npm ERR! syscall spawn
npm ERR! file sh
npm ERR! errno ENOENT
npm ERR! sqlite3@4.2.0 install: `node-pre-gyp install --fallback-to-build`
npm ERR! spawn ENOENT
npm ERR!
npm ERR! Failed at the sqlite3@4.2.0 install script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.

npm ERR! A complete log of this run can be found in:
npm ERR!     /home/pi/.npm/_logs/2021-08-18T08_55_24_888Z-debug.log

如果您对问题有任何想法。

标签: node.jsnpmraspberry-piraspberry-pi3node-sqlite3

解决方案


推荐阅读