Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Installation error: "fatal error LNK1127: library is corrupt" #200

Closed
Flourek opened this issue Nov 17, 2018 · 5 comments
Closed

Installation error: "fatal error LNK1127: library is corrupt" #200

Flourek opened this issue Nov 17, 2018 · 5 comments

Comments

@Flourek
Copy link

Flourek commented Nov 17, 2018

I've been at this for days. I've tried every solution under the sun, but none worked. I've followed the troubleshooting thoroughly, reinstalled visualstudio, nodejs, npm, node-gyp, python, made sure all of these are on the same 64bit platform. I get the same issue when trying "npm i integer", but I'm posting it here because there seems to be more activity here.

I asked a friend to try doing this, and he encountered absolutely 0 problems.
Please help. Thanks.

PS C:\Users\flour\Desktop\ay> npm install better-sqlite3
> integer@2.1.0 install C:\Users\flour\Desktop\ay\node_modules\integer
> node-gyp rebuild
C:\Users\flour\Desktop\ay\node_modules\integer>if not defined npm_config_node_gyp (node "C:\Users\flour\AppData\Roaming\npm\node_modules\npm\node_modules\npm-lifecycle\node-gyp-bin\\..\..\node_modules\node-gyp\bin\node-gyp.js" rebuild )  else (node "C:\Users\flour\AppData\Roaming\npm\node_modules\npm\node_modules\node-gyp\bin\node-gyp.js" rebuild )
Building the projects in this solution one at a time. To enable parallel build, please add the "/m" switch.
  integer.cpp
  win_delay_load_hook.cc
c:\users\flour\desktop\ay\node_modules\integer\src\integer.cpp(370): warning C4804: '-': unsafe use of type 'bool' in operation [C:\Users\flour\Desktop\ay\node_mo
dules\integer\build\integer.vcxproj]
C:\Users\flour\.node-gyp\10.13.0\x64\node.lib : fatal error LNK1127: library is corrupt [C:\Users\flour\Desktop\ay\node_modules\integer\build\integer.vcxproj]
gyp ERR! build error
gyp ERR! stack Error: `C:\Program Files (x86)\Microsoft Visual Studio\2017\BuildTools\MSBuild\15.0\Bin\MSBuild.exe` failed with exit code: 1
gyp ERR! stack     at ChildProcess.onExit (C:\Users\flour\AppData\Roaming\npm\node_modules\npm\node_modules\node-gyp\lib\build.js:262:23)
gyp ERR! stack     at ChildProcess.emit (events.js:182:13)
gyp ERR! stack     at Process.ChildProcess._handle.onexit (internal/child_process.js:240:12)
gyp ERR! System Windows_NT 10.0.17134
gyp ERR! command "C:\\Program Files\\nodejs\\node.exe" "C:\\Users\\flour\\AppData\\Roaming\\npm\\node_modules\\npm\\node_modules\\node-gyp\\bin\\node-gyp.js" "rebuild"
gyp ERR! cwd C:\Users\flour\Desktop\ay\node_modules\integer
gyp ERR! node -v v10.13.0
gyp ERR! node-gyp -v v3.8.0
gyp ERR! not ok
npm WARN ay@1.0.0 No repository field.
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! integer@2.1.0 install: `node-gyp rebuild`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the integer@2.1.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!     C:\Users\flour\AppData\Roaming\npm-cache\_logs\2018-11-17T12_36_25_820Z-debug.log
@JoshuaWise
Copy link
Member

That error message is not very descriptive, and I've never seen it before. Something is certainly wrong with your build environment, but I wouldn't know specifically.

@JoshuaWise JoshuaWise changed the title Can't install due to an issue with Integer Installation error: "fatal error LNK1127: library is corrupt" Nov 19, 2018
@Flourek
Copy link
Author

Flourek commented Nov 19, 2018

That error message is not very descriptive, and I've never seen it before. Something is certainly wrong with your build environment, but I wouldn't know specifically.

Will try messing around with the build environment, as soon as I have time. Thanks

@JoshuaWise
Copy link
Member

@Flourek Have you made any progress with your issue?

@JoshuaWise
Copy link
Member

Closing due to unresponsiveness.

@AssetKid
Copy link

Just stumbled on this bug.

C:\\Users\\[USERNAME]\\AppData\\Local\\node-gyp\\Cache\\12.18.3\\x64\\node.lib : fatal error LNK1127: library is corrupt

For future reference, deleting the node-gyp cache folder should fix this issue.

Path - C:\Users\[USERNAME]\.node-gyp or C:\Users\[USERNAME]\AppData\Local\node-gyp

Source

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Development

No branches or pull requests

3 participants