--- a/setup.py Tue Sep 20 19:25:14 2005 -0700
+++ b/setup.py Tue Sep 20 21:29:07 2005 -0700
@@ -36,7 +36,8 @@
self.includes = []
self.includes += mercurial.packagescan.getmodules(self.build_lib,'mercurial')
build_exe.finalize_options(self)
-except ImportError: pass
+except ImportError:
+ py2exe_for_demandload = None
# specify version string, otherwise 'hg identify' will be used:
@@ -50,6 +51,9 @@
try:
mercurial.version.remember_version(version)
+ cmdclass = {'install_data': install_package_data}
+ if py2exe_for_demandload is not None:
+ cmdclass['py2exe'] = py2exe_for_demandload
setup(name='mercurial',
version=mercurial.version.get_version(),
author='Matt Mackall',
@@ -64,8 +68,7 @@
['templates/map'] +
glob.glob('templates/map-*') +
glob.glob('templates/*.tmpl'))],
- cmdclass = { 'install_data' : install_package_data,
- 'py2exe' : py2exe_for_demandload},
+ cmdclass=cmdclass,
scripts=['hg', 'hgmerge'],
console = ['hg'])
finally: