From: <th...@us...> - 2009-08-14 19:44:00
|
Revision: 687 http://py2exe.svn.sourceforge.net/py2exe/?rev=687&view=rev Author: theller Date: 2009-08-14 19:43:50 +0000 (Fri, 14 Aug 2009) Log Message: ----------- Fix a DeprecationWarning in Python2.6. Modified Paths: -------------- trunk/py2exe/ChangeLog trunk/py2exe/py2exe/build_exe.py Modified: trunk/py2exe/ChangeLog =================================================================== --- trunk/py2exe/ChangeLog 2009-04-10 01:55:05 UTC (rev 686) +++ trunk/py2exe/ChangeLog 2009-08-14 19:43:50 UTC (rev 687) @@ -1,3 +1,8 @@ +2009-08-14 Thomas Heller <th...@py...> + + * Fix 'DeprecationWarning: the sets module is deprecated' in Python 2.6, + when building an executable. + 2008-04-10 Mark Hammond * If a Python 2.5 built app was installed over a Python 2.4 built app, Modified: trunk/py2exe/py2exe/build_exe.py =================================================================== --- trunk/py2exe/py2exe/build_exe.py 2009-04-10 01:55:05 UTC (rev 686) +++ trunk/py2exe/py2exe/build_exe.py 2009-08-14 19:43:50 UTC (rev 687) @@ -13,7 +13,10 @@ import sys, os, imp, types, stat import marshal import zipfile -import sets +try: + set +except NameError: + from sets import Set as set import tempfile import struct import re @@ -660,7 +663,7 @@ # make sure all targets use the same directory, this is # also the directory where the pythonXX.dll must reside - paths = sets.Set() + paths = set() for target in dist.com_server + dist.service \ + dist.windows + dist.console + dist.isapi: paths.add(os.path.dirname(target.get_dest_base())) @@ -1032,7 +1035,7 @@ # so the loadpath must be extended by our python path. loadpath = loadpath + ';' + ';'.join(pypath) - templates = sets.Set() + templates = set() if self.distribution.console: templates.add(self.get_console_template()) if self.distribution.windows: This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |