[Distutils] Patch for msvccompiler.py

Thomas Heller thomas.heller@ion-tof.com
Fri Nov 17 09:59:01 2000


This is a multi-part message in MIME format.

------=_NextPart_000_02F1_01C050AF.2B11F570
Content-Type: text/plain;
	charset="Windows-1252"
Content-Transfer-Encoding: 7bit

The attached patch converts filenames to absolute
paths before they are compiled.
This make debugging easier, because the debugger
is able to find the source files without asking the
user.

Thomas

------=_NextPart_000_02F1_01C050AF.2B11F570
Content-Type: text/plain;
	name="diff.txt"
Content-Transfer-Encoding: 7bit
Content-Disposition: attachment;
	filename="diff.txt"

Index: msvccompiler.py
===================================================================
RCS file: /cvsroot/python/distutils/distutils/msvccompiler.py,v
retrieving revision 1.42
diff -c -r1.42 msvccompiler.py
*** msvccompiler.py	2000/09/27 02:08:14	1.42
--- msvccompiler.py	2000/11/17 14:53:06
***************
*** 305,313 ****
                  self.mkpath (os.path.dirname (obj))
  
                  if ext in self._c_extensions:
!                     input_opt = "/Tc" + src
                  elif ext in self._cpp_extensions:
!                     input_opt = "/Tp" + src
                  elif ext in self._rc_extensions:
                      # compile .RC to .RES file
                      input_opt = src
--- 305,313 ----
                  self.mkpath (os.path.dirname (obj))
  
                  if ext in self._c_extensions:
!                     input_opt = "/Tc" + os.path.abspath(src)
                  elif ext in self._cpp_extensions:
!                     input_opt = "/Tp" + os.path.abspath(src)
                  elif ext in self._rc_extensions:
                      # compile .RC to .RES file
                      input_opt = src

------=_NextPart_000_02F1_01C050AF.2B11F570--