gpt4 book ai didi

c++ - 无法安装 node-sass node.lib : fatal error LNK1107: invalid or corrupt file: cannot read at 0xB8790

转载 作者:搜寻专家 更新时间:2023-11-01 00:16:45 26 4
gpt4 key购买 nike

我无法安装 node-sass。当我尝试使用 VS2015 进行编译时,我已经安装了 python2.7 和 Visual C++ 2015 Build Tools,但由于似乎缺少头文件的错误而早早地被炸毁。

我的环境

NPM 版本:v4.2.0

Node 版本:v7.10.0

Node 进程:{ http_parser: '2.7.0', Node :'7.10.0',v8: '5.5.372.43',紫外线:'1.11.0',zlib: '1.2.11',战神:'1.10.1-DEV',模块:'51',openssl: '1.0.2k',icu: '58.2',统一码:'9.0',cldr: '30.0.3',tz: '2016j'

Node 平台:win32 win10

Node 架构: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

最佳答案

你也可以试试这个:https://github.com/node-ffi/node-ffi/issues/272#issuecomment-339242933

在花费了 10 多个小时并尝试了随机解决方案/事情之后,我删除了 C:\Users\UserName\.node-gyp 文件夹并执行了 npm i 来解决依赖关系,这对我有用。

它对我有用。

关于c++ - 无法安装 node-sass node.lib : fatal error LNK1107: invalid or corrupt file: cannot read at 0xB8790,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/45093671/

26 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com