summaryrefslogtreecommitdiffstats
path: root/Lib
diff options
context:
space:
mode:
authorGreg Ward <gward@python.net>1999-12-12 17:19:58 (GMT)
committerGreg Ward <gward@python.net>1999-12-12 17:19:58 (GMT)
commit0bdd90a7e7878f451eb4915b0dc4851fac351cc1 (patch)
tree75df7c670105eb87a253b2d4c7a4a993519cb52a /Lib
parent1d0495e05c3c1155e5a1830bdeddf4ad9d4afc87 (diff)
downloadcpython-0bdd90a7e7878f451eb4915b0dc4851fac351cc1.zip
cpython-0bdd90a7e7878f451eb4915b0dc4851fac351cc1.tar.gz
cpython-0bdd90a7e7878f451eb4915b0dc4851fac351cc1.tar.bz2
Catch up with terminology change in UnixCCompiler: 'includes' -> 'include_dirs'.
Diffstat (limited to 'Lib')
-rw-r--r--Lib/distutils/ccompiler.py12
-rw-r--r--Lib/distutils/msvccompiler.py11
2 files changed, 12 insertions, 11 deletions
diff --git a/Lib/distutils/ccompiler.py b/Lib/distutils/ccompiler.py
index 486f03a..8c2ddf7 100644
--- a/Lib/distutils/ccompiler.py
+++ b/Lib/distutils/ccompiler.py
@@ -262,7 +262,7 @@ class CCompiler:
sources,
output_dir=None,
macros=None,
- includes=None,
+ include_dirs=None,
extra_preargs=None,
extra_postargs=None):
"""Compile one or more C/C++ source files. 'sources' must be
@@ -277,7 +277,7 @@ class CCompiler:
undefines a macro. Later definitions/redefinitions/
undefinitions take precedence.
- 'includes', if given, must be a list of strings, the directories
+ 'include_dirs', if given, must be a list of strings, the directories
to add to the default include file search path for this
compilation only.
@@ -489,12 +489,12 @@ def new_compiler (plat=None,
return klass (verbose, dry_run, force)
-def gen_preprocess_options (macros, includes):
+def gen_preprocess_options (macros, include_dirs):
"""Generate C pre-processor options (-D, -U, -I) as used by at
least two types of compilers: the typical Unix compiler and Visual
C++. 'macros' is the usual thing, a list of 1- or 2-tuples, where
(name,) means undefine (-U) macro 'name', and (name,value) means
- define (-D) macro 'name' to 'value'. 'includes' is just a list of
+ define (-D) macro 'name' to 'value'. 'include_dirs' is just a list of
directory names to be added to the header file search path (-I).
Returns a list of command-line options suitable for either
Unix compilers or Visual C++."""
@@ -506,7 +506,7 @@ def gen_preprocess_options (macros, includes):
# line). I don't think it's essential, though, since most (all?)
# Unix C compilers only pay attention to the latest -D or -U
# mention of a macro on their command line. Similar situation for
- # 'includes'. I'm punting on both for now. Anyways, weeding out
+ # 'include_dirs'. I'm punting on both for now. Anyways, weeding out
# redundancies like this should probably be the province of
# CCompiler, since the data structures used are inherited from it
# and therefore common to all CCompiler classes.
@@ -532,7 +532,7 @@ def gen_preprocess_options (macros, includes):
# shell at all costs when we spawn the command!
pp_opts.append ("-D%s=%s" % macro)
- for dir in includes:
+ for dir in include_dirs:
pp_opts.append ("-I%s" % dir)
return pp_opts
diff --git a/Lib/distutils/msvccompiler.py b/Lib/distutils/msvccompiler.py
index 5ac60b2..d93c74c 100644
--- a/Lib/distutils/msvccompiler.py
+++ b/Lib/distutils/msvccompiler.py
@@ -63,19 +63,20 @@ class MSVCCompiler (CCompiler) :
sources,
output_dir=None,
macros=None,
- includes=None,
+ include_dirs=None,
extra_preargs=None,
extra_postargs=None):
if macros is None:
macros = []
- if includes is None:
- includes = []
+ if include_dirs is None:
+ include_dirs = []
objectFiles = []
- base_pp_opts = gen_preprocess_options (self.macros + macros,
- self.include_dirs + includes)
+ base_pp_opts = \
+ gen_preprocess_options (self.macros + macros,
+ self.include_dirs + include_dirs)
base_pp_opts.append('/c')