File tree Expand file tree Collapse file tree 2 files changed +19
-0
lines changed Expand file tree Collapse file tree 2 files changed +19
-0
lines changed Original file line number Diff line number Diff line change @@ -358,6 +358,10 @@ extensions
358
358
objs
359
359
An array of paths to object files constituting this extension module.
360
360
361
+ required
362
+ Boolean indicating if this extension is required to initialize the Python
363
+ interpreter.
364
+
361
365
static_lib
362
366
The path to a static library defining this extension module. May not
363
367
be defined.
Original file line number Diff line number Diff line change 35
35
LOG_PREFIX = [None ]
36
36
LOG_FH = [None ]
37
37
38
+ REQUIRED_EXTENSIONS = {
39
+ '_codecs' ,
40
+ '_io' ,
41
+ '_signal' ,
42
+ '_thread' ,
43
+ '_tracemalloc' ,
44
+ '_weakref' ,
45
+ 'faulthandler' ,
46
+ 'posix' ,
47
+ }
48
+
38
49
39
50
def log (msg ):
40
51
if isinstance (msg , bytes ):
@@ -561,6 +572,10 @@ def process_setup_line(line, variant=None):
561
572
'variant' : 'default' ,
562
573
})
563
574
575
+ for extension , entries in bi ['extensions' ].items ():
576
+ for entry in entries :
577
+ entry ['required' ] = extension in REQUIRED_EXTENSIONS
578
+
564
579
# Any paths left in modules_objs are not part of any extension and are
565
580
# instead part of the core distribution.
566
581
for p in sorted (modules_objs ):
You can’t perform that action at this time.
0 commit comments