| 5 | from numpy.distutils.ccompiler_opt import CCompilerOpt |
| 6 | |
| 7 | class FakeCCompilerOpt(CCompilerOpt): |
| 8 | # disable caching no need for it |
| 9 | conf_nocache = True |
| 10 | |
| 11 | def __init__(self, arch, cc, *args, **kwargs): |
| 12 | self.fake_info = (arch, cc, '') |
| 13 | CCompilerOpt.__init__(self, None, **kwargs) |
| 14 | |
| 15 | def dist_compile(self, sources, flags, **kwargs): |
| 16 | return sources |
| 17 | |
| 18 | def dist_info(self): |
| 19 | return self.fake_info |
| 20 | |
| 21 | @staticmethod |
| 22 | def dist_log(*args, stderr=False): |
| 23 | # avoid printing |
| 24 | pass |
| 25 | |
| 26 | def feature_test(self, name, force_flags=None, macros=[]): |
| 27 | # To speed up |
| 28 | return True |
| 29 | |
| 30 | class Features: |
| 31 | def __init__(self, arch, cc): |