Attributes
- numpy_include_dirs
numpy_include_dirs = [ ]
Method summary
- __init__(self, package_name, parent_name = None, top_path = None, package_path = None, caller_level = None, attrs = 1)
- __str__(self)
- add_data_dir(self, data_path)
- add_data_files(self, files)
- add_extension(self, name, sources, kw)
- add_headers(self, files)
- add_include_dirs(self, paths)
- add_library(self, name, sources, build_info)
- add_numarray_include_dirs(self)
- add_scripts(self, files)
- add_subpackage(self, subpackage_name, subpackage_path = None, standalone = False)
- append_to(self, extlib)
- dict_append(self, dict)
- get_build_temp_dir(self)
- get_config_cmd(self)
- get_distribution(self)
- get_info(self, names)
- get_subpackage(self, subpackage_name, subpackage_path = None, parent_name = None, caller_level = 1)
- get_version(self, version_file = None, version_variable = None)
- have_f77c(self)
- have_f90c(self)
- info(self, message)
- make_config_py(self, name = '__config__')
- make_svn_version_py(self)
- paths(self, paths, kws)
- set_options(self, options)
- todict(self)
- warn(self, message)
Methods
- __init__(self, package_name, parent_name = None, top_path = None, package_path = None, caller_level = None, attrs = 1)
Construct configuration instance of a package. package_name -- name of the package Ex.: 'distutils' parent_name -- name of the parent package Ex.: 'numpy' top_path -- directory of the toplevel package Ex.: the directory where the numpy package source sits package_path -- directory of package. Will be computed by magic from the directory of the caller module if not specified Ex.: the directory where numpy.distutils is caller_level -- frame level to caller namespace, internal parameter. - __str__(self)
- add_data_dir(self, data_path)
Recursively add files under data_path to data_files list. Argument can be either - 2-sequence (<datadir suffix>,<path to data directory>) - path to data directory where python datadir suffix defaults to package dir. Rules for installation paths: foo/bar -> (foo/bar, foo/bar) -> parent/foo/bar (gun, foo/bar) -> parent/gun foo/* -> (foo/a, foo/a), (foo/b, foo/b) -> parent/foo/a, parent/foo/b (gun, foo/*) -> (gun, foo/a), (gun, foo/b) -> gun (gun/*, foo/*) -> parent/gun/a, parent/gun/b /foo/bar -> (bar, /foo/bar) -> parent/bar (gun, /foo/bar) -> parent/gun (fun/*/gun/*, sun/foo/bar) -> parent/fun/foo/gun/bar
- add_data_files(self, files)
Add data files to configuration data_files. Argument(s) can be either - 2-sequence (<datadir prefix>,<path to data file(s)>) - paths to data files where python datadir prefix defaults to package dir. Rules for installation paths: file.txt -> (., file.txt)-> parent/file.txt foo/file.txt -> (foo, foo/file.txt) -> parent/foo/file.txt /foo/bar/file.txt -> (., /foo/bar/file.txt) -> parent/file.txt *.txt -> parent/a.txt, parent/b.txt foo/*.txt -> parent/foo/a.txt, parent/foo/b.txt */*.txt -> (*, */*.txt) -> parent/c/a.txt, parent/d/b.txt (sun, file.txt) -> parent/sun/file.txt (sun, bar/file.txt) -> parent/sun/file.txt (sun, /foo/bar/file.txt) -> parent/sun/file.txt (sun, *.txt) -> parent/sun/a.txt, parent/sun/b.txt (sun, bar/*.txt) -> parent/sun/a.txt, parent/sun/b.txt (sun/*, */*.txt) -> parent/sun/c/a.txt, parent/d/b.txt
- add_extension(self, name, sources, kw)
Add extension to configuration. Keywords: include_dirs, define_macros, undef_macros, library_dirs, libraries, runtime_library_dirs, extra_objects, extra_compile_args, extra_link_args, export_symbols, swig_opts, depends, language, f2py_options, module_dirs extra_info - dict or list of dict of keywords to be appended to keywords. - add_headers(self, files)
Add installable headers to configuration. Argument(s) can be either - 2-sequence (<includedir suffix>,<path to header file(s)>) - path(s) to header file(s) where python includedir suffix will default to package name.
- add_include_dirs(self, paths)
Add paths to configuration include directories.
- add_library(self, name, sources, build_info)
Add library to configuration.
- Valid keywords for build_info:
- depends macros include_dirs extra_compiler_args f2py_options
- add_numarray_include_dirs(self)
- add_scripts(self, files)
Add scripts to configuration.
- add_subpackage(self, subpackage_name, subpackage_path = None, standalone = False)
Add subpackage to configuration.
- append_to(self, extlib)
Append libraries, include_dirs to extension or library item.
- dict_append(self, dict)
- get_build_temp_dir(self)
- get_config_cmd(self)
- get_distribution(self)
- get_info(self, names)
Get resources information.
- get_subpackage(self, subpackage_name, subpackage_path = None, parent_name = None, caller_level = 1)
Return list of subpackage configurations.
'*' in subpackage_name is handled as a wildcard.
- get_version(self, version_file = None, version_variable = None)
Try to get version string of a package.
- have_f77c(self)
Check for availability of Fortran 77 compiler. Use it inside source generating function to ensure that setup distribution instance has been initialized.
- have_f90c(self)
Check for availability of Fortran 90 compiler. Use it inside source generating function to ensure that setup distribution instance has been initialized.
- info(self, message)
- make_config_py(self, name = '__config__')
Generate package __config__.py file containing system_info information used during building the package.
- make_svn_version_py(self)
Generate package __svn_version__.py file from SVN revision number, it will be removed after python exits but will be available when sdist, etc commands are executed.
If __svn_version__.py existed before, nothing is done.
- paths(self, paths, kws)
Apply glob to paths and prepend local_path if needed.
- set_options(self, options)
Configure Configuration instance.
The following options are available: - ignore_setup_xxx_py - assume_default_configuration - delegate_options_to_subpackages - quiet
- todict(self)
Return configuration distionary suitable for passing to distutils.core.setup() function.
- warn(self, message)
