Commit fix for SF 603831.
authorGuido van Rossum <guido@python.org>
Tue, 1 Oct 2002 04:14:17 +0000 (04:14 +0000)
committerGuido van Rossum <guido@python.org>
Tue, 1 Oct 2002 04:14:17 +0000 (04:14 +0000)
Strangely, two out of three patches there seem already committed; but
the essential one (get rid of the assert in object_filenames in
ccompiler.py) was not yet applied.

This makes the build procedure for Twisted work again.

This is *not* a backport candidate despite the fact that identical
code appears to exist in 2.2.2; Twisted builds fine there, so there
must have been a change elsewhere.

Lib/distutils/ccompiler.py

index 5a0641ea5ce8770221a2210ac75bf8de102d5b14..43dfa731d28c412f5e5b35db79a6fd4e4f3fcd62 100644 (file)
@@ -876,7 +876,8 @@ class CCompiler:
     #     extension for executable files, eg. '' or '.exe'
 
     def object_filenames(self, source_filenames, strip_dir=0, output_dir=''):
-        assert output_dir is not None
+        if output_dir is None:
+            output_dir = ''
         obj_names = []
         for src_name in source_filenames:
             base, ext = os.path.splitext(src_name)