Commit 3b7000ad authored by Jason R. Coombs's avatar Jason R. Coombs

Merge setuptools.command.easy_install

--HG--
branch : Setuptools-Distribute merge
parents f179cf16 b33cf3e3
...@@ -8,6 +8,8 @@ Major Changes ...@@ -8,6 +8,8 @@ Major Changes
* Python 3 support. * Python 3 support.
* Improved support for GAE. * Improved support for GAE.
* Support `PEP-370 <http://www.python.org/dev/peps/pep-0370/>`_ per-user site
packages.
* Sort order of Distributions in pkg_resources now prefers PyPI to external * Sort order of Distributions in pkg_resources now prefers PyPI to external
links (Distribute issue 163). links (Distribute issue 163).
...@@ -16,6 +18,9 @@ Minor Changes ...@@ -16,6 +18,9 @@ Minor Changes
* Wording of some output has changed to replace contractions with their * Wording of some output has changed to replace contractions with their
canonical form (i.e. prefer "could not" to "couldn't"). canonical form (i.e. prefer "could not" to "couldn't").
* Manifest files are no longer written for .exe launchers. The
Distribute-based script launchers are used and they launch Python as a
subprocess, rather than loading the Python DLL in-process.
Differences from Distribute 0.6.35: Differences from Distribute 0.6.35:
......
...@@ -400,7 +400,7 @@ class easy_install(Command): ...@@ -400,7 +400,7 @@ class easy_install(Command):
# Is it a configured, PYTHONPATH, implicit, or explicit site dir? # Is it a configured, PYTHONPATH, implicit, or explicit site dir?
is_site_dir = instdir in self.all_site_dirs is_site_dir = instdir in self.all_site_dirs
if not is_site_dir: if not is_site_dir and not self.multi_version:
# No? Then directly test whether it does .pth file processing # No? Then directly test whether it does .pth file processing
is_site_dir = self.check_pth_processing() is_site_dir = self.check_pth_processing()
else: else:
...@@ -584,7 +584,6 @@ Please make the appropriate changes for your system and try again. ...@@ -584,7 +584,6 @@ Please make the appropriate changes for your system and try again.
spec, tmpdir, self.upgrade, self.editable, not self.always_copy, spec, tmpdir, self.upgrade, self.editable, not self.always_copy,
self.local_index self.local_index
) )
if dist is None: if dist is None:
msg = "Could not find suitable distribution for %r" % spec msg = "Could not find suitable distribution for %r" % spec
if self.always_copy: if self.always_copy:
...@@ -889,7 +888,7 @@ Please make the appropriate changes for your system and try again. ...@@ -889,7 +888,7 @@ Please make the appropriate changes for your system and try again.
f = open(pkg_inf,'w') f = open(pkg_inf,'w')
f.write('Metadata-Version: 1.0\n') f.write('Metadata-Version: 1.0\n')
for k,v in cfg.items('metadata'): for k,v in cfg.items('metadata'):
if k<>'target_version': if k!='target_version':
f.write('%s: %s\n' % (k.replace('_','-').title(), v)) f.write('%s: %s\n' % (k.replace('_','-').title(), v))
f.close() f.close()
script_dir = os.path.join(egg_info,'scripts') script_dir = os.path.join(egg_info,'scripts')
...@@ -1184,7 +1183,6 @@ See the setuptools documentation for the "develop" command for more info. ...@@ -1184,7 +1183,6 @@ See the setuptools documentation for the "develop" command for more info.
def pf(src,dst): def pf(src,dst):
if dst.endswith('.py') and not src.startswith('EGG-INFO/'): if dst.endswith('.py') and not src.startswith('EGG-INFO/'):
to_compile.append(dst) to_compile.append(dst)
to_chmod.append(dst)
elif dst.endswith('.dll') or dst.endswith('.so'): elif dst.endswith('.dll') or dst.endswith('.so'):
to_chmod.append(dst) to_chmod.append(dst)
self.unpack_progress(src,dst) self.unpack_progress(src,dst)
...@@ -1223,6 +1221,7 @@ See the setuptools documentation for the "develop" command for more info. ...@@ -1223,6 +1221,7 @@ See the setuptools documentation for the "develop" command for more info.
def no_default_version_msg(self): def no_default_version_msg(self):
return """bad install directory or PYTHONPATH return """bad install directory or PYTHONPATH
...@@ -1506,7 +1505,7 @@ def get_exe_prefixes(exe_filename): ...@@ -1506,7 +1505,7 @@ def get_exe_prefixes(exe_filename):
('PURELIB/', ''), ('PLATLIB/pywin32_system32', ''), ('PURELIB/', ''), ('PLATLIB/pywin32_system32', ''),
('PLATLIB/', ''), ('PLATLIB/', ''),
('SCRIPTS/', 'EGG-INFO/scripts/'), ('SCRIPTS/', 'EGG-INFO/scripts/'),
('DATA/LIB/site-packages', ''), ('DATA/lib/site-packages', ''),
] ]
z = zipfile.ZipFile(exe_filename) z = zipfile.ZipFile(exe_filename)
try: try:
...@@ -1517,7 +1516,7 @@ def get_exe_prefixes(exe_filename): ...@@ -1517,7 +1516,7 @@ def get_exe_prefixes(exe_filename):
if parts[1].endswith('.egg-info'): if parts[1].endswith('.egg-info'):
prefixes.insert(0,('/'.join(parts[:2]), 'EGG-INFO/')) prefixes.insert(0,('/'.join(parts[:2]), 'EGG-INFO/'))
break break
if len(parts)<>2 or not name.endswith('.pth'): if len(parts)!=2 or not name.endswith('.pth'):
continue continue
if name.endswith('-nspkg.pth'): if name.endswith('-nspkg.pth'):
continue continue
...@@ -1838,7 +1837,7 @@ def get_script_args(dist, executable=sys_executable, wininst=False): ...@@ -1838,7 +1837,7 @@ def get_script_args(dist, executable=sys_executable, wininst=False):
launcher = launcher.replace(".", "-64.") launcher = launcher.replace(".", "-64.")
else: else:
launcher = launcher.replace(".", "-32.") launcher = launcher.replace(".", "-32.")
if os.path.exists(new_header[2:-1]) or sys.platform!='win32': if os.path.exists(new_header[2:-1].strip('"')) or sys.platform!='win32':
hdr = new_header hdr = new_header
else: else:
hdr = header hdr = header
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment