Hi Everyone,
I am not a conversant c++ user, however, I have used this library before (https://github.com/nukedzn/node-tcl) using node 8 and currently its maintainer has not attended to it and does not compile with node 12+. It gives some deprecated errors.
Would anyone be kind to help me change the library so that it compiles. From what I can see only a few errors come up and they may be very trivial to someone who is familiar with c++.
I don't want to install a gazillion things to get to the point you are at.. esp on my work pc...
it looks like *something* in the js is trying to call the c++ but missed a parameter.
if you can get the js to provide that, it may just work (or it may spawn 20 more problems).
if it was working before, and isnt now, its probably not a missing param inside the actual c++ code, in other words. Could be something broken in the build / make for the .o file though...
its one or the other -- js calling wrong or build of the c++ isnt quite right...
There is no js calling as yet. I tend to agree with you that it is the latter. Some thing to do with the build of c++. Because when you npm install it compiles and builds the .o files in the build directory. This is the step that is failing.
Building the same code using a lower version of node produces no errors and the build directory is complete to be used at runtime by js.
The library is pretty small around 85K and 24MB when npm install downloads the node_modules.
It would be really appreciated if one can download and attempt to compile to see the build errors.
I won't promise to set all that up. I may, but its not doable @ work and @ home depends on what my wife has in mind for me to do over the weekend!
but if you can figure out exactly how node is trying to compile the c++ (the generated makefile or g++ command or whatever it is doing) and post that, it would tell us a LOT about what is going on.
Thanks again for your reply Jonnin and I wish you and your family a great weekend.
From my experience, npm libraries can be pure javascript or can have some c/c++ code to extend nodejs. Using node-gyp you can build for the target version of node js. This library was targeting older version up to 8. https://www.npmjs.com/package/node-gyp
as shown above, when npm install is done inside the library directory it downloads the required files and then executes node-gyp rebuild to create the build for the currently installed node js version. I have installed version 12 from nodejs.org and it breaks using that as shown above.
Thanks again for your interest and awaiting your courteous reply.