summaryrefslogtreecommitdiff
path: root/setuptools/command/install_scripts.py
diff options
context:
space:
mode:
authorJason R. Coombs <jaraco@jaraco.com>2015-01-18 19:54:01 -0500
committerJason R. Coombs <jaraco@jaraco.com>2015-01-18 19:54:01 -0500
commite43d3b0acbeacba3aea066af73546c7278116a6f (patch)
tree2080c301a4d627a6fb76adedb811ec6aa255a094 /setuptools/command/install_scripts.py
parente8de6a1034a811c19be7ad8760c918a482cef9c8 (diff)
downloadpython-setuptools-bitbucket-e43d3b0acbeacba3aea066af73546c7278116a6f.tar.gz
Defer resolution of the CommandSpec and do it exactly once.
Diffstat (limited to 'setuptools/command/install_scripts.py')
-rwxr-xr-xsetuptools/command/install_scripts.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/setuptools/command/install_scripts.py b/setuptools/command/install_scripts.py
index f85f4520..af079fbb 100755
--- a/setuptools/command/install_scripts.py
+++ b/setuptools/command/install_scripts.py
@@ -31,13 +31,13 @@ class install_scripts(orig.install_scripts):
)
bs_cmd = self.get_finalized_command('build_scripts')
exec_param = getattr(bs_cmd, 'executable', None)
- cmd = ei.CommandSpec.from_param(exec_param)
bw_cmd = self.get_finalized_command("bdist_wininst")
is_wininst = getattr(bw_cmd, '_is_running', False)
writer = ei.ScriptWriter
if is_wininst:
- cmd = ei.CommandSpec.from_string("python.exe")
+ exec_param = "python.exe"
writer = ei.WindowsScriptWriter
+ cmd = ei.CommandSpec.from_param(exec_param)
for args in writer.best().get_args(dist, cmd.as_header()):
self.write_script(*args)