bnoordhuis / node-buffertools

working with node.js buffers made easy
ISC License
205 stars 35 forks source link

A dynamic link library (DLL) initialization routine failed #94

Open wizzardio opened 5 years ago

wizzardio commented 5 years ago

I have a win32 application for Card Reading (I also use nw.js) and in this application I need to include pcsclite. When I installed it I received an error : buffertools.node is not valid win32 application windows.

I used node-gyp to configure and build it via commands:

 node-gyp configure --arch=ia32 --target_platform=win32 -msvs_version=2015
 node-gyp build --arch=ia32 --target_platform=win32 -msvs_version=2015

This error disappeared and I received another:

A dynamic link library (DLL) initialization routine failed.
node_modules\buffertools\build\Release\buffertools.node

Maybe, someone will be able to give some hint how I can handle it? I use: node 9.11.1 npm 6.4.1 win 10 / 64

Please, let me know in case of any questions.

Thanks in advance.

bnoordhuis commented 5 years ago

--arch=... should match node -p process.arch. It probably should be 'x64' instead of 'ia32'.

bnoordhuis commented 5 years ago

Oh, and note that node.js v9.x is end of life. You should upgrade to the latest v10.x or v11.x.

wizzardio commented 5 years ago

sorry, I didn't want to close. I tried to rebuild my project on win64 + libraries. Also, I used 10.15.3 node and --arch=x64.

Same issue.