On Monday 2016-03-14 16:02, Michael Matz wrote:
On Mon, 14 Mar 2016, Yamaban wrote:
contain timestamps of their source file and will not be used unless it matches exactly. Why do we (and redhat) even include them? In Debian packages have only .py files and the precompiled .pyc files get added upon package installation.
I wonder if .pyc or .pyo bring any advantages at all at this time?
On slow HW, esp with rotating rust, YES.
Any numbers to convince me? :)
On rotating rust it might just be the opposite - spending the time saved on compilation on seeks as directories now have thrice the amount of files.
But "compile on install" ala debian - best controlled by config setting - seems the the way to go forward fast in this aspect.
Actually I would do such compilation in a deferred scheme, not directly at install time (or well, maybe that's acceptable as well if not taking too much time).
Generally you do not want to increase install times, as they are already big by inevitably system-dependent things like mkinitrd and fonts-config. pyc files however are not so much system dependent as they are architecture dependent, so it's better to spend that build time in .spec files. That would also make it easier for them to be tracked by rpm.