Update of /cvsroot/pywin32/pywin32
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv1515
Modified Files:
MANIFEST.in pywin32_postinstall.py setup_win32all.py
Added Files:
pywin32.pth
Log Message:
Just copy the .pth file in like any other file rather than creating
it dynamically. This means that simply "unzipping" one of these
distributions should largely work.
Index: pywin32_postinstall.py
===================================================================
RCS file: /cvsroot/pywin32/pywin32/pywin32_postinstall.py,v
retrieving revision 1.16
retrieving revision 1.17
diff -C2 -d -r1.16 -r1.17
*** pywin32_postinstall.py 9 Oct 2004 02:44:03 -0000 1.16
--- pywin32_postinstall.py 10 Oct 2004 22:15:16 -0000 1.17
***************
*** 129,147 ****
import distutils.sysconfig
import traceback
# Create the .pth file in the site-packages dir, and use only relative paths
lib_dir = distutils.sysconfig.get_python_lib(plat_specific=1)
! # Used to write this directly to sys.prefix - clobber it.
if os.path.isfile(os.path.join(sys.prefix, "pywin32.pth")):
os.unlink(os.path.join(sys.prefix, "pywin32.pth"))
! fname = os.path.join(lib_dir, "pywin32.pth")
! if verbose:
! print "Creating .PTH file %s" % fname
! pthfile = open(fname, "w")
! # Register the file with the uninstaller
! file_created(fname)
for name in "win32 win32\\lib Pythonwin".split():
- # Create entries for the PTH file, and at the same time
- # add the directory to sys.path so we can load win32api below.
- pthfile.write(name + "\n")
sys.path.append(os.path.join(lib_dir, name))
# It is possible people with old versions installed with still have
--- 129,141 ----
import distutils.sysconfig
import traceback
+ # The .pth file is now installed as a regular file.
# Create the .pth file in the site-packages dir, and use only relative paths
lib_dir = distutils.sysconfig.get_python_lib(plat_specific=1)
! # We used to write a .pth directly to sys.prefix - clobber it.
if os.path.isfile(os.path.join(sys.prefix, "pywin32.pth")):
os.unlink(os.path.join(sys.prefix, "pywin32.pth"))
! # The .pth may be new and therefore not loaded in this session.
! # Setup the paths just in case.
for name in "win32 win32\\lib Pythonwin".split():
sys.path.append(os.path.join(lib_dir, name))
# It is possible people with old versions installed with still have
Index: MANIFEST.in
===================================================================
RCS file: /cvsroot/pywin32/pywin32/MANIFEST.in,v
retrieving revision 1.4
retrieving revision 1.5
diff -C2 -d -r1.4 -r1.5
*** MANIFEST.in 6 Oct 2004 05:13:00 -0000 1.4
--- MANIFEST.in 10 Oct 2004 22:15:16 -0000 1.5
***************
*** 5,8 ****
--- 5,9 ----
include MANIFEST.in
+ include pywin32.pth
# Core win32 stuff
include win32/src/*.rc
Index: setup_win32all.py
===================================================================
RCS file: /cvsroot/pywin32/pywin32/setup_win32all.py,v
retrieving revision 1.36
retrieving revision 1.37
diff -C2 -d -r1.36 -r1.37
*** setup_win32all.py 8 Oct 2004 21:51:25 -0000 1.36
--- setup_win32all.py 10 Oct 2004 22:15:16 -0000 1.37
***************
*** 1177,1180 ****
--- 1177,1181 ----
# Note we don't get an auto .pyc - but who cares?
('', ('com/pythoncom.py',)),
+ ('', ('pywin32.pth',)),
],
)
--- NEW FILE: pywin32.pth ---
# .pth file for the PyWin32 extensions
win32
win32\lib
Pythonwin
|