Skip to content

Conversation

@pxinwr
Copy link
Contributor

@pxinwrpxinwr commented Dec 24, 2020

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
Copy link

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

@github-actionsgithub-actionsbot added the stale Stale PR or inactive for long period of time. label Jan 29, 2021
@pxinwrpxinwrforce-pushed the fix-issue-31904-dispycopt branch from 6c08216 to 6077cdeCompareFebruary 20, 2021 08:21
@pxinwrpxinwr changed the title bpo-31904: add --enable-pyc-build --enable-opt1-pyc-build and --enable-opt2-pyc-build option for configurebpo-31904: add --enable-pyc-build option to the configure scriptFeb 20, 2021
@pxinwrpxinwrforce-pushed the fix-issue-31904-dispycopt branch from 6077cde to 2a1efdaCompareMay 7, 2021 01:44
@pxinwrpxinwrforce-pushed the fix-issue-31904-dispycopt branch from 32aafd8 to 0d3b908CompareMay 7, 2021 06:44
@matrixise
Copy link
Member

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

@pxinwrpxinwr closed this May 7, 2021
@pxinwrpxinwr reopened this May 7, 2021
@gpshead
Copy link
Member

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).

@pxinwrpxinwr changed the title bpo-31904: add --enable-pyc-build option to the configure scriptbpo-44097: add --enable-pyc-build option to the configure scriptMay 10, 2021
@pxinwr
Copy link
ContributorAuthor

@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
Copy link
Member

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

@github-actionsgithub-actionsbot removed the stale Stale PR or inactive for long period of time. label Aug 2, 2022
@kuhlenoughkuhlenoughmannequin mentioned this pull request Jan 12, 2024
@encukou
Copy link
Member

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.

@encukouencukou closed this Mar 28, 2024
Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

8 participants

@pxinwr@matrixise@gpshead@tiran@encukou@the-knights-who-say-ni@ezio-melotti@bedevere-bot