-
-
Notifications
You must be signed in to change notification settings - Fork 553
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
SINGULAR_SO default is incorrect of Cygwin #22628
Comments
comment:2
So on Cygwin there is no "symlink" |
comment:3
Generally DLLs do not go in In any case, I think it's better to explicitly point to the platform-specific location of a shared library. (In fact, rather than hard-coding this it would be better if there were a routine to get shared library paths in a platform-specific way. |
comment:4
Replying to @embray:
That said, for the purposes of |
comment:5
There is still a potential problem when changing Singular versions. Then multiple DLLs might be installed. How do you know which is the correct one? |
comment:6
Would there be though? I worried about this too, but I thought any previous version would be uninstalled before installing a new version. |
comment:7
Replying to @embray:
remove_old_version()
{
# the following is a little verbose but it ensures we leave no trace of 3.x
# _or_ 4.x
rm -f "$SAGE_LOCAL"/bin/*Singular*
rm -f "$SAGE_LOCAL"/bin/*singular*
rm -rf "$SAGE_LOCAL/include/singular" # 3.x and 4.x
rm -rf "$SAGE_LOCAL/include/factory" # 3.x and 4.x
rm -f "$SAGE_LOCAL/include/factor.h" # 3.x only
rm -f "$SAGE_LOCAL/include/factoryconf.h" # 3.x only
rm -rf "$SAGE_LOCAL/include/omalloc" #4.x only
rm -f "$SAGE_LOCAL/include/omalloc.h" # 3.x only
rm -f "$SAGE_LOCAL/include/omlimits.h" # 3.x only
rm -rf "$SAGE_LOCAL/include/resources" #4.x only
rm -rf "$SAGE_LOCAL/include/gfanlib" #4.x only
rm -f "$SAGE_LOCAL"/lib/libsingular* # 3.x with lower case
rm -f "$SAGE_LOCAL"/lib/libsingcf*.a # 3.x only additional archives
rm -f "$SAGE_LOCAL"/lib/libsingfac*.a # 3.x only additional archives
rm -f "$SAGE_LOCAL"/lib/libSingular* # 4.x with upper case
rm -f "$SAGE_LOCAL"/lib/p_Procs_Field* # 3.x only
# a bunch of additional libraries for 4.x
rm -f "$SAGE_LOCAL"/lib/libpolys*
rm -f "$SAGE_LOCAL"/lib/libfactory*
rm -f "$SAGE_LOCAL"/lib/libomalloc*
rm -f "$SAGE_LOCAL"/lib/libresources*
rm -r "$SAGE_LOCAL"/lib/libgfan*
rm -rf "$SAGE_LOCAL/share/singular"
rm -f "$SAGE_LOCAL"/share/info/singular*
} which doesn't deal with any of the Cygwin names for the library (that would be another good reason why Cygwin should just the name |
comment:8
See #22652 |
comment:9
Yeah, that's pretty hideous, which is why I wrote #22510. In the meantime I'll update the existing "uninstall" to handle Cygwin better. Unfortunately the DLL naming can't be changed. |
comment:10
At the very least the Singular |
Branch pushed to git repo; I updated commit sha1. New commits:
|
comment:12
This ensures Singular will be "uninstalled" better when upgrading on Cygwin. This way there really should only be one Much as it's not nice to have platform-specific checks in |
Branch pushed to git repo; I updated commit sha1. New commits:
|
comment:14
Don't hardcode the extension. OS X uses |
comment:15
Ah, right. I'll leave it for Cygwin but remove it for the 'else' case. |
Branch pushed to git repo; I updated commit sha1. New commits:
|
Reviewer: Jeroen Demeyer |
comment:20
I think I had I agree |
comment:21
Replying to @embray:
The That seems like something which shouldn't happen and I'd rather see an error in that case.
At least, it's very clear where the error happens. Setting |
comment:22
Yeah. I didn't put it there. |
comment:23
Better a more explicit error message in that "later" case then. Or earlier, if you prefer. My thinking was just that it might be nice to be able to import |
comment:24
Replying to @embray:
I'm not entirely sure that I follow you. You did change |
comment:25
No, I added an entirely new line that used |
comment:26
Replying to @embray:
Any comment on this? This is the only thing keeping this from having positive_review. There should be an explicit error message if a valid path for |
comment:28
Ping? FYI - I needed this to build on Cygwin. |
comment:29
If Jeroen doesn't mind I could switch this back over to my branch and just add the minor fix I'm proposing. It's mostly just a nitpick. |
Changed branch from u/jdemeyer/cygwin/singular_so to u/embray/cygwin/singular_so |
Changed author from Erik Bray to Erik Bray, Jeroen Demeyer |
comment:30
Went ahead and did what I had in mind. This will error out very early on in New commits:
|
Branch pushed to git repo; I updated commit sha1. New commits:
|
Changed reviewer from Jeroen Demeyer to Jeroen Demeyer, Volker Braun |
Changed dependencies from #21957 to none |
Changed branch from u/embray/cygwin/singular_so to |
It should be under
$SAGE_LOCAL/bin/cygSingular-<version>.dll
. Rather than guess at the version the attached patch just takes the latest one (which will normally be the only one). It's pretty hacky, but then so is this code on other platforms too.For the purposes of the standard Sage distribution this should generally work though.
Component: porting: Cygwin
Author: Erik Bray, Jeroen Demeyer
Branch/Commit:
cb3dadf
Reviewer: Jeroen Demeyer, Volker Braun
Issue created by migration from https://trac.sagemath.org/ticket/22628
The text was updated successfully, but these errors were encountered: