PS D:\report\source\lpd-planning-allocation> yarn yarn install v1.3.2 [1/4] Resolving packages... [2/4] Fetching packages... info fsevents@1.1.2: The platform "win32" is incompatible with this module. info "fsevents@1.1.2" is an optional dependency and failed compatibility check. Excluding it from installation. [3/4] Linking dependencies... [4/4] Building fresh packages... [1/2] ⠄ dtrace-provider [2/2] ⠄ sharp: C:\Users\chenwes\.node-gyp\8.9.4\x64\node.lib : fatal error LNK1127: ������ [D:\report\esquel\lpd-planning-allocation\node_modules\sharp\build\sharp.vcxproj] [-/2] ⠄ waiting... [-/2] ⠄ waiting... error D:\report\source\lpd-planning-allocation\node_modules\sharp: Command failed. Exit code: 1 Command: node-gyp rebuild Arguments: Directory: D:\report\esquel\lpd-planning-allocation\node_modules\sharp Output: D:\report\source\lpd-planning-allocation\node_modules\sharp>if not defined npm_config_node_gyp (node "C:\Program Files\nodejs\node_modules\npm\bin\node-gyp-bin\\..\..\node_modules\node-gyp\bin\node-gyp.js" rebuild ) else (node "" rebuild ) gyp info it worked
nodejs安装sharp出错的问题
最新推荐文章于 2024-08-23 15:22:44 发布
在安装Node.js的sharp库时遇到错误,需要确保Python版本在v2.5.0到3.0.0之间。通过运行'yarn config set python C:\Python27\python.exe'设置Python路径为2.7版本即可解决。
摘要由CSDN通过智能技术生成