(filename,
incldirs=None,
includes=None,
macros=None,
samefiles=None,
cwd=None,
)
| 69 | |
| 70 | |
| 71 | def preprocess(filename, |
| 72 | incldirs=None, |
| 73 | includes=None, |
| 74 | macros=None, |
| 75 | samefiles=None, |
| 76 | cwd=None, |
| 77 | ): |
| 78 | if not cwd or not os.path.isabs(cwd): |
| 79 | cwd = os.path.abspath(cwd or '.') |
| 80 | filename = _normpath(filename, cwd) |
| 81 | |
| 82 | postargs = POST_ARGS |
| 83 | basename = os.path.basename(filename) |
| 84 | dirname = os.path.basename(os.path.dirname(filename)) |
| 85 | if (basename not in FILES_WITHOUT_INTERNAL_CAPI |
| 86 | and dirname not in DIRS_WITHOUT_INTERNAL_CAPI): |
| 87 | postargs += ('-DPy_BUILD_CORE=1',) |
| 88 | |
| 89 | text = _common.preprocess( |
| 90 | TOOL, |
| 91 | filename, |
| 92 | incldirs=incldirs, |
| 93 | includes=includes, |
| 94 | macros=macros, |
| 95 | #preargs=PRE_ARGS, |
| 96 | postargs=postargs, |
| 97 | executable=['gcc'], |
| 98 | compiler='unix', |
| 99 | cwd=cwd, |
| 100 | ) |
| 101 | return _iter_lines(text, filename, samefiles, cwd) |
| 102 | |
| 103 | |
| 104 | def _iter_lines(text, reqfile, samefiles, cwd, raw=False): |
no test coverage detected
searching dependent graphs…