]> git.ipfire.org Git - thirdparty/Python/cpython.git/commitdiff
See SF #848614: distutils' msvccompiler now tries to detect that MSVC6
authorThomas Heller <theller@ctypes.org>
Fri, 28 Nov 2003 19:35:58 +0000 (19:35 +0000)
committerThomas Heller <theller@ctypes.org>
Fri, 28 Nov 2003 19:35:58 +0000 (19:35 +0000)
is installed but the registry settings are incomplete because the gui
has never been run.

Lib/distutils/msvccompiler.py
Misc/NEWS

index 5f3d8de87232c5a3c75b0776fe2aebcd4751a19c..27fb658b5bb9b8373832663d4882019460e18143 100644 (file)
@@ -547,6 +547,16 @@ class MSVCCompiler (CCompiler) :
                     return string.split(self.__macros.sub(d[path]), ";")
                 else:
                     return string.split(d[path], ";")
+        # MSVC 6 seems to create the registry entries we need only when
+        # the GUI is run.
+        if self.__version == 6:
+            for base in HKEYS:
+                if read_values(base, r"%s\6.0" % self.__root) is not None:
+                    self.warn("It seems you have Visual Studio 6 installed, "
+                        "but the expected registry settings are not present.\n"
+                        "You must at least run the Visual Studio GUI once "
+                        "so that these entries are created.")
+                break
         return []
 
     def set_path_env_var(self, name):
index 53ef6f034d46f56ebc90b8aa89bf22c5eac03daa..0d64252cfd75c66741ef70bc6c488c08f859eca3 100644 (file)
--- a/Misc/NEWS
+++ b/Misc/NEWS
@@ -63,8 +63,11 @@ Extension modules
 Library
 -------
 
+- Bug #848614: distutils' msvccompiler fails to find the MSVC because
+  of incomplete registry entries.
+
 - Patch #841977: modulefinder didn't find extension modules
-  in packages
+  in packages.
 
 - Bug #792101: Add missing file operations for httplib.SSLFile.