From 7f6ef6ca269051528777bba20865d087bcbf9cc7 Mon Sep 17 00:00:00 2001 From: Greg Ward Date: Wed, 22 Mar 2000 00:20:46 +0000 Subject: [PATCH] Renamed 'install_path' to 'extra_path'. Fix 'Command.set_undefined_option()' to call 'ensure_ready()' rather than 'finalize_options()' (which is only supposed to be called once, which is the whole point of 'ensure_ready()'). Added comment to 'set_peer_option()' to remind myself that this method cannot work and is fundamentally wrong-headed. --- Lib/distutils/core.py | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/Lib/distutils/core.py b/Lib/distutils/core.py index dfe411b0ccd..2f3a36d7d0f 100644 --- a/Lib/distutils/core.py +++ b/Lib/distutils/core.py @@ -197,7 +197,7 @@ class Distribution: self.ext_modules = None self.ext_package = None self.include_dirs = None - self.install_path = None + self.extra_path = None # And now initialize bookkeeping stuff that can't be supplied by # the caller at all. 'command_obj' maps command names to @@ -840,7 +840,7 @@ class Command: # Option_pairs: list of (src_option, dst_option) tuples src_cmd_obj = self.distribution.find_command_obj (src_cmd) - src_cmd_obj.finalize_options () + src_cmd_obj.ensure_ready () try: for (src_option, dst_option) in option_pairs: if getattr (self, dst_option) is None: @@ -862,6 +862,10 @@ class Command: second 'finalize_options()' invocation will have little or no effect.""" + # XXX this won't work -- must call finalize_option to work, but + # calling finalize_option is wrong (it's only supposed to be called + # once). Where is this needed?!??! + cmd_obj = self.distribution.find_command_obj (command) cmd_obj.set_option (option, value) cmd_obj.finalize_options ()