bpo-44097: add --enable-pyc-build option to the configure script by pxinwr · Pull Request #23920 · python/cpython (original) (raw)

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 andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Conversation6 Commits1 Checks0 Files changed

Conversation

This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.Learn more about bidirectional Unicode characters

[ Show hidden characters]({{ revealButtonHref }})

pxinwr

Currently when you build and install Python out of source, unoptimized .pyc files and 2 types of optimized .pyc files(.opt-1.pyc and *.opt-2.pyc) are all compiled out and installed. So to reduce package size and build and installation time, we should provide options in configure to disable them.

https://bugs.python.org/issue44097

@github-actions

This PR is stale because it has been open for 30 days with no activity.

@pxinwr pxinwr changed the titlebpo-31904: add --enable-pyc-build --enable-opt1-pyc-build and --enable-opt2-pyc-build option for configure bpo-31904: add --enable-pyc-build option to the configure script

Feb 20, 2021

@pxinwr

@matrixise

@pxinwr Please, don't push force, it's not necessary. Thank you

@gpshead

https://bugs.python.org/issue31904

This PR really should have its own build enhancement BPO issue as it isn't specific to the vxworks one. Can you file a new bug and update the issue title to point to it?

I do think this makes sense, though some discussion over what the name of the configure flag should be and the wording of its descriptive text makes sense (probably better do settle on that in the bug).

@pxinwr pxinwr changed the titlebpo-31904: add --enable-pyc-build option to the configure script bpo-44097: add --enable-pyc-build option to the configure script

May 10, 2021

@pxinwr

@gpshead Thanks for your comments. I've filed a new bug# 44097 for this issue. For the name and description text, hopes someone can help to polish.

@tiran

I'm -1 on complicating configure and Makefile. You could delete unwanted variants with find -name '*.opt-2.pyc' -delete after installation.

@pxinwr pxinwr mannequin mentioned this pull request

Apr 10, 2022

@encukou

Sorry for the delay.
Nowadays compileall all levels at once, and it should be a bit easier to limit the opt levels it produces. See the issue.

I don't think we can use the changes in this PR, so I'll close it.