-
-
Notifications
You must be signed in to change notification settings - Fork 33.1k
bpo-45798: Move _decimal build setup into configure (GH-29541) #29541
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
Conversation
81b53bc to
ecac9ff
Compare
|
🤖 New build scheduled with the buildbot fleet by @tiran for commit ecac9ff9a7b6933faa088261b347bed627ac3a08 🤖 If you want to schedule another build, you need to add the ":hammer: test-with-buildbots" label again. |
ecac9ff to
69d4720
Compare
69d4720 to
698947a
Compare
Settings for :mod:`decimal` internal C extension are now detected by :program:`configure`. The bundled `libmpdec` library is built in ``Makefile``. Signed-off-by: Christian Heimes <christian@python.org>
698947a to
78dabef
Compare
| Modules/_decimal/libmpdec/fourstep.o \ | ||
| Modules/_decimal/libmpdec/io.o \ | ||
| Modules/_decimal/libmpdec/mpalloc.o \ | ||
| Modules/_decimal/libmpdec/mpdecimal.o \ |
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.
I see that mpsignal.o is missing here; presumably that's because we don't actually make any use of it? Is the omission worth a comment? (bench and bench_full are also missing, but the reason for those is more obvious)
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.
I didn't include it because setup.py's detect_decimal does not include mpsignal.o either. It doesn't hurt to include the object. The linker should drop any unused symbol from the final library anyway.
bench and bench_full are programs with main function. We cannot include them.
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.
I added a build rule and comment for mpsignal.o.
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.
Looks fine to me in principle; the code changes look good to my eyes, though I don't think I'm qualified to review the fine details here.
I'm currently testing the build on my home machine (macOS 10.14.6) both with bundled and external libmpdec (in the latter case, using mpdecimal 2.5.1 from MacPorts); I'll report back here if I see any issues.
|
Some suspicious-looking output from the decimal test suite when using the bundled libmpdec: I'm also seeing a number of tests skipped with: |
Scratch that. It also appears on the main branch, and there's an explicit notice at the top of the test suite output telling us to disregard. It shouldn't really be surprising that an attempt to allocate 0.4 exabytes of RAM fails. The |
I cannot reproduce the issue locally.
You have to enable the feature in |
|
Okay, confession time: I don't actually know how to build Python against the MacPorts mpdecimal, either on main or on this branch. :-( That has little to do with this PR, but I would have liked to have checked that it still worked. |
I verified |
Settings for :mod:`decimal` internal C extension are now detected by :program:`configure`. The bundled `libmpdec` library is built in ``Makefile``. Signed-off-by: Christian Heimes <christian@python.org>
Settings for :mod:`decimal` internal C extension are now detected by :program:`configure`. The bundled `libmpdec` library is built in ``Makefile``. Signed-off-by: Christian Heimes <christian@python.org>
Settings for :mod:
decimalinternal C extension are now detected by:program:
configure. The bundledlibmpdeclibrary is built inMakefile.Signed-off-by: Christian Heimes christian@python.org
https://bugs.python.org/issue45798