|
|
报错信息:8 d" g! O' m. J K
```bash; g2 b0 |# \4 w# }# Z$ R/ T
gyp ERR! find VS
/ ]% l0 Y' w% x% v& _9 G7 bgyp ERR! find VS msvs_version not set from command line or npm config% V- V3 O8 s# X) j5 ]+ P- R* `& V. S
gyp ERR! find VS running in VS Command Prompt, installation path is:
5 ?7 R; Z: T$ J/ ?+ i. F ygyp ERR! find VS "C:\Program Files (x86)\Microsoft Visual Studio\2017"
2 ]: o: H, P# c. zgyp ERR! find VS - will only use this version4 M. u" g' O0 z- u+ M! y
gyp ERR! find VS could not use PowerShell to find Visual Studio 2017 or newer. h" K& l, M9 y, l, Z$ E6 S! L
gyp ERR! find VS looking for Visual Studio 2015- ^% @% y* `! G8 q' K" P
gyp ERR! find VS - not found
- y3 t% n3 r# a' L$ Fgyp ERR! find VS looking for Visual Studio 2013
* T' {: g$ C: X2 |gyp ERR! find VS - not found
3 V0 R6 I" {. q% z0 w# j1 m, Tgyp ERR! find VS7 o& X$ |3 t2 X) F0 }7 J0 h$ J8 M4 c
gyp ERR! find VS **************************************************************1 I2 o/ j" T; Y8 j O8 m' e* V
gyp ERR! find VS You need to install the latest version of Visual Studio$ e/ M( J! R0 p* M+ }* S
gyp ERR! find VS including the "Desktop development with C++" workload.
- J1 k$ Q/ B/ n# X# `5 v% M' Mgyp ERR! find VS For more information consult the documentation at:
: Q c( u3 {8 C7 r& jgyp ERR! find VS https://github.com/nodejs/node-gyp#on-windows) V( \4 }5 N( a E
gyp ERR! find VS **************************************************************' x3 y7 m8 x" k5 p: V. W
gyp ERR! find VS
4 T1 ?6 M% B5 P5 U+ ^1 M7 {gyp ERR! configure error5 x6 U) A0 U4 _
gyp ERR! stack Error: Could not find any Visual Studio installation to use, r" |7 c& Z+ ~( D
gyp ERR! stack at VisualStudioFinder.fail (D:\rymcu\electron-serialport\node_modules\node-gyp\lib\find-visualstu
$ I" \" Q: V v) kdio.js:121:47)
- W3 t" M0 U: m; S7 T0 d% ?7 ggyp ERR! stack at D:\rymcu\electron-serialport\node_modules\node-gyp\lib\find-visualstudio.js:74:16 i5 _3 R- T' _- f. `
gyp ERR! stack at D:\rymcu\electron-serialport\node_modules\node-gyp\lib\find-visualstudio.js:372:16
3 F9 R0 M, v1 Q+ N8 m" Vgyp ERR! stack at D:\rymcu\electron-serialport\node_modules\node-gyp\lib\util.js:54:7: v& R9 C {: P8 i9 g3 f0 d; c
gyp ERR! stack at D:\rymcu\electron-serialport\node_modules\node-gyp\lib\util.js:33:165 B$ ^% ]0 G6 V& h* f
gyp ERR! stack at ChildProcess.exithandler (child_process.js:310:5)8 s5 W3 y: _$ i2 T" S
gyp ERR! stack at ChildProcess.emit (events.js:315:20); N& P3 {, P) Q" b- _6 I1 m
gyp ERR! stack at maybeClose (internal/child_process.js:1021:16): p, \! O9 N/ q. ]- K1 F
gyp ERR! stack at Process.ChildProcess._handle.onexit (internal/child_process.js:286:5)
6 b2 G! g/ C# P+ ?1 Ygyp ERR! System Windows_NT 10.0.15063 ' R) V. E% G5 }; i2 P
% t% w1 m" g8 Y- o: f: U解决办法
" t M+ q% d# C8 }. E/ Z1、卸载nodejs重新安装一遍, g( c. S- C( u
; }; J) s# K' E; z
2、设置淘宝镜像 npm config set registry https://registry.npm.taobao.org
, |6 S; i$ z8 E- C7 x) U5 G/ U* @0 ^
3、安装nodejs所需的环境(Visual Studio XX、python什么鬼的),执行这个命令会自动检测并帮你安装好,npm install --g --production windows-build-tools
! _, H# U+ p; p5 m$ g————————————————6 E1 a6 t. D& d2 t3 X. t3 S
版权声明:本文为CSDN博主「一点一滴成长」的原创文章,遵循CC 4.0 BY-SA版权协议,转载请附上原文出处链接及本声明。
- u9 ` q4 b5 M5 ?6 S# V原文链接:https://blog.csdn.net/qq_39946015/article/details/127351920 |
|