Closed Bug 384962 Opened 18 years ago Closed 8 years ago

building creates config/Expression.pyc in source directory

Categories

(Firefox Build System :: General, defect)

defect
Not set
trivial

Tracking

(Not tracked)

RESOLVED INVALID

People

(Reporter: myk, Unassigned)

References

Details

After building Firefox on the trunk to an object directory, an Expression.pyc file appeared in the config subdirectory of the source directory. Building to an object directory isn't supposed to create files in the source directory, and this compiled Python file could perhaps cause problems if the source directory was later used to build for a different architecture, so the build system shouldn't be creating this file in the source directory.
Python creates the .pyc files automatically at runtime and doesn't have configuration options where to put them AFAICT, unless do do some weird-ass shit overriding the default import action. If you have a readonly srcdir does the build fail or succeed?
(In reply to comment #0) > > Building to an object directory isn't supposed to create files in the source > directory, and this compiled Python file could perhaps cause problems if the > source directory was later used to build for a different architecture, so the > build system shouldn't be creating this file in the source directory. Python bytecode files are cross-platform, iirc. They are not reusable across major Python versions, and have a magic number to prevent the loading of incompatible bytecode. (In reply to comment #1) > Python creates the .pyc files automatically at runtime and doesn't have > configuration options where to put them AFAICT, py_compile and compileall will let you specify where to put pyc files. Not sure it's worth the trouble.
(In reply to comment #1) > If you have a readonly srcdir does the build fail or succeed? The build succeeds (as expected, since Python doesn't depend on being able to create a .pyc file).
Severity: normal → trivial
OS: Mac OS X → All
Hardware: PC → All
.pyc files in source dirs are still an issue. But this bug doesn't seem to be in an actionable state. So closing.
Status: NEW → RESOLVED
Closed: 8 years ago
Resolution: --- → INVALID
Product: Core → Firefox Build System
You need to log in before you can comment on or make changes to this bug.