0

I am having lots of trouble trying to compile a wxpython application into an exe file. py2exe keeps giving me errors and won't compile my code to an exe. The following is what happens when I run a simple setup.py script. I am on windows 64 bit and python 2.7 and using py2exe 64 bit. (bundling does not work in 64 bit py2exe. not sure if that poses a problem) I believe I have all the right DLLs installed since I have microsoft visual studio installed. Any help would be appreciated.

*** searching for required modules *** *** parsing results *** creating python loader for extension 'P4API' (C:\Python27\lib\site-packages\P4AP I.pyd -> P4API.pyd) creating python loader for extension 'wx._misc_' (C:\Python27\lib\site-packages\ wx-2.8-msw-unicode\wx\_misc_.pyd -> wx._misc_.pyd) creating python loader for extension 'select' (C:\Python27\DLLs\select.pyd -> se lect.pyd) creating python loader for extension 'unicodedata' (C:\Python27\DLLs\unicodedata .pyd -> unicodedata.pyd) creating python loader for extension 'wx._windows_' (C:\Python27\lib\site-packag es\wx-2.8-msw-unicode\wx\_windows_.pyd -> wx._windows_.pyd) creating python loader for extension 'wx._core_' (C:\Python27\lib\site-packages\ wx-2.8-msw-unicode\wx\_core_.pyd -> wx._core_.pyd) creating python loader for extension 'wx._gdi_' (C:\Python27\lib\site-packages\w x-2.8-msw-unicode\wx\_gdi_.pyd -> wx._gdi_.pyd) creating python loader for extension 'wx._controls_' (C:\Python27\lib\site-packa ges\wx-2.8-msw-unicode\wx\_controls_.pyd -> wx._controls_.pyd) creating python loader for extension 'bz2' (C:\Python27\DLLs\bz2.pyd -> bz2.pyd) *** finding dlls needed *** Traceback (most recent call last): File "setup.py", line 4, in <module> setup(windows=['PerforceApp.py']) File "C:\Python27\lib\distutils\core.py", line 152, in setup dist.run_commands() File "C:\Python27\lib\distutils\dist.py", line 953, in run_commands self.run_command(cmd) File "C:\Python27\lib\distutils\dist.py", line 972, in run_command cmd_obj.run() File "C:\Python27\lib\site-packages\py2exe\build_exe.py", line 243, in run self._run() File "C:\Python27\lib\site-packages\py2exe\build_exe.py", line 305, in _run dlls = self.find_dlls(extensions) File "C:\Python27\lib\site-packages\py2exe\build_exe.py", line 389, in find_dl ls self.dll_excludes) File "C:\Python27\lib\site-packages\py2exe\build_exe.py", line 1064, in find_d ependend_dlls bin_depends(loadpath, images + [sys.executable], excludes_use) File "C:\Python27\lib\site-packages\py2exe\build_exe.py", line 1441, in bin_de pends if isSystemDLL(dll): File "C:\Python27\lib\site-packages\py2exe\build_exe.py", line 1498, in isSyst emDLL raise Exception, "Seems not to be an exe-file" Exception: Seems not to be an exe-file 

1 Answer 1

1

I had the same problem that was caused by the "MSVCP90.dll" file, so i added this directive to my setup.py and now it works like a charm!

dll_excludes = ['MSVCP90.dll'] 
Sign up to request clarification or add additional context in comments.

Comments

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.