Show More
@@ -252,12 +252,6 b" needs_setuptools = set(('develop', 'release', 'bdist_egg', 'bdist_rpm'," | |||
|
252 | 252 | 'bdist', 'bdist_dumb', 'bdist_wininst', 'bdist_wheel', |
|
253 | 253 | 'egg_info', 'easy_install', 'upload', 'install_egg_info', |
|
254 | 254 | )) |
|
255 | if sys.platform == 'win32': | |
|
256 | # Depend on setuptools for install on *Windows only* | |
|
257 | # If we get script-installation working without setuptools, | |
|
258 | # then we can back off, but until then use it. | |
|
259 | # See Issue #369 on GitHub for more | |
|
260 | needs_setuptools.add('install') | |
|
261 | 255 | |
|
262 | 256 | if len(needs_setuptools.intersection(sys.argv)) > 0: |
|
263 | 257 | import setuptools |
@@ -403,6 +403,16 b' class build_scripts_entrypt(build_scripts):' | |||
|
403 | 403 | with open(outfile, 'w') as f: |
|
404 | 404 | f.write(script_src.format(executable=sys.executable, |
|
405 | 405 | mod=mod, func=func)) |
|
406 | ||
|
407 | if sys.platform == 'win32': | |
|
408 | # Write .cmd wrappers for Windows so 'ipython' etc. work at the | |
|
409 | # command line | |
|
410 | cmd_file = os.path.join(self.build_dir, name + '.cmd') | |
|
411 | cmd = '@"{python}" "%~dp0\{script}" %*\r\n'.format( | |
|
412 | python=sys.executable, script=name) | |
|
413 | log.info("Writing %s wrapper script" % cmd_file) | |
|
414 | with open(cmd_file, 'w') as f: | |
|
415 | f.write(cmd) | |
|
406 | 416 | |
|
407 | 417 | return outfiles, outfiles |
|
408 | 418 |
General Comments 0
You need to be logged in to leave comments.
Login now