Commit a937afd3 authored by Guido van Rossum's avatar Guido van Rossum

Freeze assumes that all built-in modules are part of the Python core.

This is not necessarily the case.  It is possible to create a Python
binary which contains built-in extension modules.  Therefore
checkextensions should be used for all unknown and builtin modules.
(Sjoerd Mullender)
parent 1abfb9c0
...@@ -338,13 +338,15 @@ def main(): ...@@ -338,13 +338,15 @@ def main():
# search for unknown modules in extensions directories (not on Windows) # search for unknown modules in extensions directories (not on Windows)
addfiles = [] addfiles = []
addmoddefns = [] # Windows list of modules. addmoddefns = [] # Windows list of modules.
if unknown: if unknown or (not win and builtins):
if not win: if not win:
addfiles, addmods = \ addfiles, addmods = \
checkextensions.checkextensions(unknown, extensions) checkextensions.checkextensions(unknown+builtins,
extensions)
for mod in addmods: for mod in addmods:
unknown.remove(mod) if mod in unknown:
builtins = builtins + addmods unknown.remove(mod)
builtins.append(mod)
else: else:
# Do the windows thang... # Do the windows thang...
import checkextensions_win32 import checkextensions_win32
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment