-
-
Notifications
You must be signed in to change notification settings - Fork 424
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
Use libdl.so.2 instead of libdl #1499
Conversation
Nearly all (or all if only counting LSB conforming) Linux distros have libdl.so.2, and usually don't have a libdl.so symlink unless dev packages are installed. Fixes dotnet#1492
@dotnet-policy-service agree |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is a functionally breaking change that will impact compatibility with older operating systems that we support today.
Oh I just saw Beyleys comment on the issue. Happy for them to make the call here but I’m worried about this one. |
I dont think is breaking on any distro in use today, the LSB was written in jan 1997 and all modern distros have agreed on this, as stated in the other issue, if a distro doesnt comply with LSB, it probably cant run dotnet in the first place, i feel like this is a safe breaking change |
I don't really have much say in this, but I'm also a bit concerned here on several levels.
If it doesn't compy with LSB in this specific scenario, so can only resolve I also remember that some distro (FreeBSD, I think?) does not have resolving After some research it seems this may be rooted in the runtime not adding the I myself run arch, but have not encountered this issue, and am unsure how to reproduce exactly. Also an somewhat unqualified note on the standards mentioned, I cannot find these ever talking about specific file names. There is So yeah, I think this is a very fragile system both from our side and from the various distros, it has many issues and just changing it without very good reason and verification is dangerous! |
*BSDs are not Linux (they're just another Unix branch) and Silk doesn't use libdl for this case, it just directly uses libc. libdl.so is required for C compilation, yes, but again, (also, not being available being it just doesn't have the symlink to libdl.so.2, no symlink means ld can't resolve it, ld doesn't have any magic here, the magic is in the symlinks) The DllNotFoundException is thrown on the first invocation of some libdl function used (which then only would occur when the DllImport function could not resolve the dll, or .so in this case). Also again to be clear, you would need to be using .NET Standard or .NET Framework to reproduce this, along with some distro which does not have a libdl.so (you can usually check this by |
Even on my Arch machine with many AUR packages and compiler etc., there is no Even though netfx and ns2.0 are basically dead, there is still an amount of people stuck on it due to legacy codebases/libraries, who rely on it when publishing I feel like this change at most breaks old non-standard distros, and at the least has no effect, this change should definitely be listed on the changelog though. If you are okay with this being merged @Perksey, id like to get this in, since we have gotten people in the past in the discord still using netfx/mono for some reason or another (like ppc64 linux platforms which have no .NET core runtime and use distro packaged mono) This is an intentional change by the glibc people btw, libdl is no more, its been consumed by the main libc |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Beyleys call
Merging for now, can be reverted if unforseen issues arise later on, making a mental note to explain this on the changelog sidenote: osu-framework has been using |
Had a report that this is invoking some weird behaviour on Android, need to take a closer look at this. |
Nearly all (or all if only counting LSB conforming) Linux distros have libdl.so.2, and usually don't have a libdl.so symlink unless dev packages are installed.
Fixes #1492