Open DDuarte opened 8 years ago
Ah good point! When Peter and I looked at this, only Node 0.10 and 0.12 were relevant. Is there any way to dynamically fetch the DLL-name based on node-gyp?
Or at least, if I remember correctly, the version Node was compiled with needs to match the version the libraries get compiled with.
I'm afraid it doesn't matter what Node or node-gyp uses.
Right now (however this could change if more file formats are added and so on), the only thing that matters is that the runtime DLL specified in c-lib
matches the runtime linked with libblp (because fopen
is used as an argument to blp_processFile
).
Honestly I don't know how to make this generic. At least, after version 14.0 (VS 2015), the runtime library filename is no longer versioned (there's no msvcr140
), only ucrtbase(d).
Related to #51
The file
c-lib.js
hardcodes the VC runtime librarymsvcr120
making it only compatible with DLLs built with Visual Studio 2013. This causes Node to crash when external DLLS (libstorm.dll
,libblp.dll
) are compiled with a different VS version, e.g,ucrtbase
/ucrtbased
should be used if compiling with VS 2015 (or above).