numpy.distutils.ccompiler.CCompiler_compile#
- distutils.ccompiler.CCompiler_compile(self, sources, output_dir=None, macros=None, include_dirs=None, debug=0, extra_preargs=None, extra_postargs=None, depends=None)[source]#
Compile one or more source files.
Please refer to the Python distutils API reference for more details.
- Parameters
- sourceslist of str
A list of filenames
- output_dirstr, optional
Path to the output directory.
- macroslist of tuples
A list of macro definitions.
- include_dirslist of str, optional
The directories to add to the default include file search path for this compilation only.
- debugbool, optional
Whether or not to output debug symbols in or alongside the object file(s).
- extra_preargs, extra_postargs?
Extra pre- and post-arguments.
- dependslist of str, optional
A list of file names that all targets depend on.
- Returns
- objectslist of str
A list of object file names, one per source file sources.
- Raises
- CompileError
If compilation fails.