【发布时间】:2017-12-19 00:08:50
【问题描述】:
我无法安装 node-sass。 我已经安装了 python2.7 和 Visual C++ 2015 构建工具,当我尝试使用 VS2015 进行编译时,但由于似乎缺少头文件错误而更早地被炸毁了。
我的环境
NPM 版本:v4.2.0
节点版本:v7.10.0
节点进程: { http_parser: '2.7.0', 节点:'7.10.0', v8: '5.5.372.43', 紫外线:'1.11.0', zlib: '1.2.11', 战神:'1.10.1-DEV', 模块:'51', openssl: '1.0.2k', 重症监护室:'58.2', unicode: '9.0', cldr:'30.0.3', tz: '2016j' }
节点平台:win32 win10
节点架构:x64
node-sass 版本:错误:找不到模块“node-sass”
npm node-sass 版本(``):没有
错误:
npm i --save-dev node-sass
....
....
Release\obj\binding\win_delay_load_hook.obj
"D:\Project\GitRepositorys\awesome-TPC\node_modules\node-sass\build\Release\libsass.lib"
C:\Users\Administrator\.node-gyp\7.10.0\x64\node.lib : fatal error LNK1107: invalid or corrupt file: cannot read at 0xB8790 [D:\Project\ GitRepositorys\awesome-TPC\node_modules\node-sass\build\binding.vcxproj]
gyp ERR! build error
gyp ERR! stack Error: `C:\Program Files (x86)\MSBuild\14.0\bin\msbuild.exe` failed with exit code: 1
gyp ERR! stack at ChildProcess.onExit (D:\Project\GitRepositorys\awesome-TPC\node_modules\node-gyp\lib\build.js:258:23)
gyp ERR! stack at emitTwo (events.js:106:13)
gyp ERR! stack at ChildProcess.emit (events.js:194:7)
gyp ERR! stack at Process.ChildProcess._handle.onexit (internal/child_process.js:215:12)
gyp ERR! System Windows_NT 10.0.15063
gyp ERR! command "C:\\Program Files\\nodejs\\node.exe" "D:\\Project\\GitRepositorys\\awesome-TPC\\node_modules\\node-gyp\\bin\\node-gyp.js" "rebuild" "--verbose" "--libsass_ext=" "--libsass_cflags=" "--libsass_ldflags=" "--libsass_library="
gyp ERR! cwd D:\Project\GitRepositorys\awesome-TPC\node_modules\node-sass
gyp ERR! node -v v7.10.0
gyp ERR! node-gyp -v v3.6.2
gyp ERR! not ok
【问题讨论】:
标签: c++ node.js node-gyp node-sass