aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/Lib/distutils/ccompiler.py
diff options
context:
space:
mode:
Diffstat (limited to 'Lib/distutils/ccompiler.py')
-rw-r--r--Lib/distutils/ccompiler.py6
1 files changed, 5 insertions, 1 deletions
diff --git a/Lib/distutils/ccompiler.py b/Lib/distutils/ccompiler.py
index 751ec0694bc..ebd93c27eb0 100644
--- a/Lib/distutils/ccompiler.py
+++ b/Lib/distutils/ccompiler.py
@@ -691,7 +691,11 @@ class CCompiler:
depends, extra_postargs)
cc_args = self._get_cc_args(pp_opts, debug, extra_preargs)
- for obj, (src, ext) in build.items():
+ for obj in objects:
+ try:
+ src, ext = build[obj]
+ except KeyError:
+ continue
self._compile(obj, src, ext, cc_args, extra_postargs, pp_opts)
# Return *all* object filenames, not just the ones we just built.