diff options
author | Moshe Zadka <moshez@math.huji.ac.il> | 2001-03-31 16:09:32 +0000 |
---|---|---|
committer | Moshe Zadka <moshez@math.huji.ac.il> | 2001-03-31 16:09:32 +0000 |
commit | bc62dc04ace89153801952051bdae154d89c105b (patch) | |
tree | 1afa6a3a8c4ddc3d47b875f59740b45d212a68f9 | |
parent | 2f9d1cfec1c3d2b92a7ad5716fca11ab8b69b45e (diff) | |
download | cpython-bc62dc04ace89153801952051bdae154d89c105b.tar.gz |
- #233253 - distutils/command/build_ext.py - the --define and --undef options
didn't work, whether specified on the command-line or in setup.cfg.
- distutils/command/build_ext.py - make docstrings raw
- #128930 - distutils/command/build_ext.py - split rpath argument
Suggested by AMK, but had to be massaged a bit from the cvs diff
-rw-r--r-- | Lib/distutils/command/build_ext.py | 20 | ||||
-rw-r--r-- | Misc/NEWS | 7 |
2 files changed, 26 insertions, 1 deletions
diff --git a/Lib/distutils/command/build_ext.py b/Lib/distutils/command/build_ext.py index 70e8a73455..c1bce26755 100644 --- a/Lib/distutils/command/build_ext.py +++ b/Lib/distutils/command/build_ext.py @@ -151,6 +151,8 @@ class build_ext (Command): self.library_dirs = [] if self.rpath is None: self.rpath = [] + elif type(self.rpath) is StringType: + self.rpath = string.split(self.rpath, os.pathsep) # for extensions under windows use different directories # for Release and Debug builds. @@ -161,6 +163,22 @@ class build_ext (Command): self.build_temp = os.path.join(self.build_temp, "Debug") else: self.build_temp = os.path.join(self.build_temp, "Release") + + # The argument parsing will result in self.define being a string, but + # it has to be a list of 2-tuples. All the preprocessor symbols + # specified by the 'define' option will be set to '1'. Multiple + # symbols can be separated with commas. + + if self.define: + defines = string.split(self.define, ',') + self.define = map(lambda symbol: (symbol, '1'), defines) + + # The option for macros to undefine is also a string from the + # option parsing, but has to be a list. Multiple symbols can also + # be separated with commas here. + if self.undef: + self.undef = string.split(self.undef, ',') + # finalize_options () @@ -528,7 +546,7 @@ class build_ext (Command): return self.package + '.' + ext_name def get_ext_filename (self, ext_name): - """Convert the name of an extension (eg. "foo.bar") into the name + r"""Convert the name of an extension (eg. "foo.bar") into the name of the file from which it will be loaded (eg. "foo/bar.so", or "foo\bar.pyd"). """ @@ -155,6 +155,13 @@ http://sourceforge.net/tracker/index.php?func=detail&aid=<id>&group_id=5470&atid - pyexpat.c - removed memory leaks +- #233253 - distutils/command/build_ext.py - the --define and --undef options + didn't work, whether specified on the command-line or in setup.cfg. + +- distutils/command/build_ext.py - make docstrings raw + +- #128930 - distutils/command/build_ext.py - split rpath argument + What's New in Python 2.0? ========================= |