-
-
Notifications
You must be signed in to change notification settings - Fork 491
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
python2/3: split spkg-install to spkg-build; fix various build issues #23781
Comments
comment:2
Given that these scripts are mostly the same for Python 2 and Python 3, would it be possible to have just one script (say, by symlinking) and then use |
comment:3
Looking at the difference between the Python 2 and Python 3 scripts, I wonder why this only occurs for Python 2:
I think this is just an omission and it should be there for Python 3 also. |
comment:4
Apart from that, everything looks fine from looking at the diff. |
comment:5
Replying to @jdemeyer:
I've wondered that myself. It's tempting--maybe this ticket would be a good place to do it as long as I'm making changes... |
comment:6
Replying to @jdemeyer:
Apparently you added that in #19899, but didn't add it to python3, presumably just due to lack of python3 testing at the time. Probably it applies there too. |
comment:7
Replying to @embray:
Great! Please do. |
comment:8
For some reason I thought I already did this. I guess I'll finish this up now since this is a dependency of #22509, which I'd also really like to move forward on. |
Branch pushed to git repo; I updated commit sha1. This was a forced push. New commits:
|
comment:11
As suggested, merged the mostly duplicate scripts into one (this will be much better maintenance-wise going forward). This required one small change to |
comment:12
I see that you are checking for the importability of various modules before installing Python. That makes sense, but it also means that you can remove the duplicate check
|
comment:13
Maybe also fold both import checks into one by doing something like
|
comment:14
Please explain this:
We didn't need this before... |
comment:15
Just replace it with |
comment:16
Replying to @jdemeyer:
Actually you did, you just didn't know it :) I try to write reasonably descriptive commit messages: sagemath/sagetrac-mirror@cab490e |
comment:17
Replying to @jdemeyer:
I'm not honestly even sure what that check is for (or why it was ever separate to begin with). Could you provide some background? |
comment:18
Replying to @jdemeyer:
Oops--carry over from a merge conflict resolution. I'll fix that. |
Reviewer: Jeroen Demeyer |
comment:28
I don't agree with the The problem with the current approach is that those
Without this patch, this |
comment:29
If you want to fix the |
comment:30
I see what you're saying, but this is a problem that needs to be solved somehow. I don't want to make a separate ticket because a) I'm sick of refactoring b) At some point (weeks ago, so I can't remember why) this was important enough to add to this ticket, because without it something was breaking. |
comment:31
Replying to @embray:
What do you think of my proposal to fix the Python upstream build system to put |
comment:32
Replying to @jdemeyer:
I'd definitely be fine with that--I'm just going to look around a bit more to see if there isn't already a solution to this. It seems odd to me that there wouldn't be. |
comment:33
Okay, there is a better solution, which in retrospect is obvious--instead of exporting
This does not change the defaults that are saved to the Whether or not this is an upstream bug is debatable, but I'll ask on python-dev. |
Branch pushed to git repo; I updated commit sha1. New commits:
|
comment:35
How does this looks? It seems to work for me. If you still really want me to make a separate ticket for the link issue I can do so; I would just prefer not to bother. |
comment:36
I just need to test this, but your explanation sounds OK. |
comment:37
Replying to @embray:
If there is an easy fix, that's fine. It's just that I'd rather finish this ticket instead of keeping struggling with this one issue. |
Changed branch from u/embray/build/python to u/jdemeyer/build/python |
comment:39
Looks good to me. One final thing: when making such substantial changes to the build/install scripts, it is safer to increase the patchlevel of the packages (even if one could argue that this is not strictly needed). I did that in a follow-up commit. Do you agree? New commits:
|
comment:41
Yes--I think that's an unfortunate quirk of how we do continuous integration for Sage, but under the current circumstances I think it makes sense. |
Changed branch from u/jdemeyer/build/python to |
This ticket starts by splitting the
spkg-install
for python2 and python3 into separatespkg-build
andspkg-install
scripts as recommended by #21726 (we said we would apply this change to individual packages on a case-by-case basis, and I figured as long as I was making changes to these scripts it would be good to do).This also fixes a general bug with the build, where building a new Python can link the python executable and extension modules with an old libpython left in
$SAGE_LOCAL
, leading to possible errors.Rather than deleting the old libpython first, I think it's cleaner to pass the correct
$LDFLAGS
to prevent this from happening.Finally, this moves the tests that certain extension modules built to after building, but before installing, and runs the tests out of the source directory. This is a change extracted from #22509.
Component: packages: standard
Keywords: python2 python3
Author: Erik Bray
Branch/Commit:
f326c1a
Reviewer: Jeroen Demeyer
Issue created by migration from https://trac.sagemath.org/ticket/23781
The text was updated successfully, but these errors were encountered: