-
Notifications
You must be signed in to change notification settings - Fork 30.3k
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
Windows Node 6.3.0 binary exports SSL symbols #7608
Comments
See #6274 for where this comes from; so, yes, it’s intended that these symbols are available to addons, but of course not that they conflict with other libraries. /cc @bnoordhuis @nodejs/platform-windows |
With what options is that add-on compiled and linked? |
It's quite a big project with several other 3rd party libraries. Because of this I'm also not using node-gyp to build as it would be quite hard to get this manageable. Anyhow, I found meanwhile that I can workaround/solve this via the sequence of the libs passed to the linker: I have to ensure that I first pass my 3rd parties (libcurl + ssl,..) first and node.lib at the end. No idea why the linker is no longer complaining then as the number of symbols doesn't change because of this... |
I'm going to guess that your libcurl_a.lib indiscriminately re-exports symbols from its own dependencies, creating conflicts (or not) depending on the final link order. On UNIX platforms, you normally compile static libraries with |
MSVC acts like gcc with But this is not really the area of my issue as it defines what is visible from the dso/exe created by link step - my issue happens during this link step where libs are put together. Anyhow, I know how to proceed and that the change in node was intended. From my point of view this issue can be closed. Thanks for you fast help! |
Right, that's certainly the case for DLLs and executables (it took me a godawful amount of work to get those openssl symbols exported from node.exe) but my understanding is that in static libraries everything is public by default.
I'll close then, cheers! |
Yes, for static libs everything is public for MSVC - and also for gcc. |
Edit: Asking my questions in a separate thread in the help repo. Just a heads up here that https://github.com/nodegit/nodegit is having issues with this as well, and we're using node-gyp. |
I'm having a similar problem at the issue linked above (nodejs/node-gyp#1559), and I would love some help there. |
I work on a project using a native addon where libcurl is used.
If I build with node 6.3.0 headers/libs I get a linker error because of duplicate symbols:
Looks like node 6.3.0 exports SSL functions for some reason which was not the case for 6.2.2.
Is this intended?
The text was updated successfully, but these errors were encountered: