File tree 1 file changed +9
-5
lines changed
1 file changed +9
-5
lines changed Original file line number Diff line number Diff line change @@ -1437,12 +1437,16 @@ def add_caching_dir_configvars():
1437
1437
add_numba_configvars ()
1438
1438
1439
1439
# TODO: `gcc_version_str` is used by other modules.. Should it become an immutable config var?
1440
- try :
1441
- p_out = output_subprocess_Popen ([config .cxx , "-dumpversion" ])
1442
- gcc_version_str = p_out [0 ].strip ().decode ()
1443
- except OSError :
1444
- # Typically means gcc cannot be found.
1440
+ if config .cxx != "" :
1441
+ try :
1442
+ p_out = output_subprocess_Popen ([config .cxx , "-dumpversion" ])
1443
+ gcc_version_str = p_out [0 ].strip ().decode ()
1444
+ except OSError :
1445
+ # Typically means gcc cannot be found.
1446
+ gcc_version_str = "GCC_NOT_FOUND"
1447
+ else :
1445
1448
gcc_version_str = "GCC_NOT_FOUND"
1449
+
1446
1450
# TODO: The caching dir resolution is a procedural mess of helper functions, local variables
1447
1451
# and config definitions. And the result is also not particularly pretty..
1448
1452
add_caching_dir_configvars ()
You can’t perform that action at this time.
0 commit comments