[Patches] [ python-Patches-677103 ] PYTHONBYTECODEBASE patch (PEP 304)

SourceForge.net noreply@sourceforge.net
Thu, 30 Jan 2003 14:51:53 -0800


Patches item #677103, was opened at 2003-01-29 16:49
You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=305470&aid=677103&group_id=5470

Category: Core (C code)
Group: Python 2.3
Status: Open
Resolution: None
Priority: 5
Submitted By: Skip Montanaro (montanaro)
Assigned to: Skip Montanaro (montanaro)
Summary: PYTHONBYTECODEBASE patch (PEP 304)

Initial Comment:
This is just a placeholder patch related to PEP 304.  Feel free to
comment on it.  It's far from complete at this point.  The first
patch is just to see if we can do all the proper detection at
startup.  These checks have to be performed before any .py
files are imported, otherwise you'd have some .pyc files dumped
out before the machinery is ready to go.

The first patch contains mods to sysmodule.c with next to
no concern for platform independence.  There is a small shell
script and a few expected output files which are used to
test setting of various values.  These should probably be
wrapped into regular PyUnit tests which popen() the interpreter
with different settings, but this seemed quicker as a start.

----------------------------------------------------------------------

>Comment By: Skip Montanaro (montanaro)
Date: 2003-01-30 16:51

Message:
Logged In: YES 
user_id=44345

While not technically broken, the patch I just posted is a bit bent.
Withdrawing for a little fixup...

----------------------------------------------------------------------

Comment By: Skip Montanaro (montanaro)
Date: 2003-01-30 16:33

Message:
Logged In: YES 
user_id=44345

Here's an updated context diff.  It seems to do the right thing on my
Mac OS X system.  It won't currently do anything on Windows ( need help
there).  No more test cases, but if PYTHONBYTECODEBASE points to
a valid directory, the .pyc files seem to get put in all the right places.

To get the behavior, you'll have to configure --with-bytecodebase.

Feedback, please...

----------------------------------------------------------------------

Comment By: Skip Montanaro (montanaro)
Date: 2003-01-29 16:52

Message:
Logged In: YES 
user_id=44345

second upload try - what the hell is with SF?

----------------------------------------------------------------------

You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=305470&aid=677103&group_id=5470