Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit e9e20a9

Browse files
committed
[ 684677 ] Allow freeze to exclude implicits
1 parent c49435c commit e9e20a9

1 file changed

Lines changed: 6 additions & 3 deletions

File tree

Tools/freeze/freeze.py

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -130,9 +130,6 @@ def main():
130130

131131
fail_import = exclude[:]
132132

133-
# modules that are imported by the Python runtime
134-
implicits = ["site", "exceptions"]
135-
136133
# output files
137134
frozen_c = 'frozen.c'
138135
config_c = 'config.c'
@@ -202,6 +199,12 @@ def main():
202199
f,r = a.split("=", 2)
203200
replace_paths.append( (f,r) )
204201

202+
# modules that are imported by the Python runtime
203+
implicits = []
204+
for module in ('site', 'exceptions',):
205+
if module not in exclude:
206+
implicits.append(module)
207+
205208
# default prefix and exec_prefix
206209
if not exec_prefix:
207210
if prefix:

0 commit comments

Comments
 (0)