()
| 18 | |
| 19 | |
| 20 | def get_processor(): |
| 21 | # Convoluted because we can't import from numpy.distutils |
| 22 | # (numpy is not yet built) |
| 23 | conv_template_path = os.path.join( |
| 24 | os.path.dirname(__file__), |
| 25 | '..', '..', 'distutils', 'conv_template.py' |
| 26 | ) |
| 27 | spec = importlib.util.spec_from_file_location( |
| 28 | 'conv_template', conv_template_path |
| 29 | ) |
| 30 | mod = importlib.util.module_from_spec(spec) |
| 31 | spec.loader.exec_module(mod) |
| 32 | return mod.process_file |
| 33 | |
| 34 | |
| 35 | process_c_file = get_processor() |