-
Notifications
You must be signed in to change notification settings - Fork 162
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
Fix a problem with kernel extensions on macOS #5235
Fix a problem with kernel extensions on macOS #5235
Conversation
On macOS, kernel extensions built against non-installed GAP could not be loaded into an executable built using libgap, such as `tst/testlibgap/basic`. Resolve this by building kernel extensions again with flat namespace (thus matching the behavior of the Linux dynamic linker more closely), as we used to when we were still using libtool for kernel extensions This problem was only relevant for non-installed GAP builds. For GAP installed via `make install` and kernel extensions built against that, all was and is fine.
This seem to be the case only for some values of |
ok, good, this allows the test proposed in #5234 to pass. |
Was the That said, the error message references
So, how exactly do you build packages? To be sure, I just did a test with a fresh GAP 4.12.1, and it all worked fine:
|
Maybe try inserting |
this is how we'll build gap 4.12.1: and here is how we build more gap packages: anyway, I've backported the patch in the PR to 4.12.1, and everything is back to normal on macOS, too |
not sure what the test you mention is meant to test. to test this pr, one needs to fix #5234 to that
|
well, it's all fine as is, no extra copies of |
The test refutes your claim in https://trac.sagemath.org/ticket/34391 elsewhere that there is a problem with The patch in this PR fixes a genuine issue, but I believe that issue is merley a symptom of the problem in the Sage trac, not the root cause. Rather, I suspect the problem is with how Sage builds, tests and installs GAP.
This misses the point: there is indeed no extra That's why I suggested to add Of course this is just a guess, and it might be wrong, but I still think it would be prudent to do this cleaning in |
there is no problem whatsoever with
why "not yet installed"? Later, optionally, I have no idea why in this case the same
no, it does not exist at this point. Because |
OK, I don't know how Sage builds stuff, and playing guessing games with you when you refuse to try what I suggest is not leading anywhere. But that's fine by me, ultimately I don't care if there is a deeper issue with the Sage setup or not shrug But you are wrong about #5234 resp. #5232 -- what you do there is build But it is not needed if one properly builds |
I have no idea what you want me to try. I have explained to you that there are no stale copy of
but "installed" GAP does not "use" libgap in any way. I just don't understand what you are talking about.
I don't understand. In Sage we are building |
In #5235 (comment) you attempted to "disprove" that there is nothing to fix if loading |
In view of #5232 (comment), can we have a backport to 4.12 of this ? |
If this is your advice, you'd need to provide a way to build kernel extensions specifically for |
Sorry for the confusion: I missed that PR #5193 is not yet in stable-4.12 and hence also not in 4.12.1. So what I said above is only for GAP master and for the future 4.12.2. |
Backported to stable-4.12 via commit aed43ee |
On macOS, kernel extensions built against non-installed GAP could not be loaded into an executable built using libgap, such as
tst/testlibgap/basic
. Resolve this by building kernel extensions again with flat namespace (thus matching the behavior of the Linux dynamic linker more closely), as we used to when we were still using libtool for kernel extensionsThis problem was only relevant for non-installed GAP builds. For GAP installed via
make install
and kernel extensions built against that, all was and is fine.Resolves #5232
(To be clear: in general kernel extensions are highly specific to the GAP they were built again, using one built against a non-installed GAP in a different executable built against
libgap
is not a good idea in general; but since it was trivial to get it working in this case, I did it; but on the long run I expect this to be problematic for other reasons, so I'd advise against it)