0

I'm trying to make an exe for a python program I developed, with py2exe. I managed to do it, but I can't figure out the last problem I have: include the msvcr100.dll.

I tried to follow the tutorial here: http://www.py2exe.org/index.cgi/Tutorial

But they do it with an old version of Visual Studio. I installed visual studio 2010 express, and the files are not even in the same directory.

So, as my program will be used by only one person, I simply copied the dll in the same directory as the exe. But when I try to run the exe on a fresh windows install, I get an error message: "The application or the dll MSVCR100.dll is not a valid windows "image" (translation from french, sorry. I don't even know what that means in my own language).

Could you give me a hand please ?

JPFrancoia
  • 4,866
  • 10
  • 43
  • 73

1 Answers1

0

Don't install Visual Studio. Install Visual C++ Redistributable 2008 and 2010.

Malik Brahimi
  • 16,341
  • 7
  • 39
  • 70
  • Ok, thanks, if I install that on a windows fresh install, my program runs. But isn't there a way to include the dll in my dist directory ? I just want the final user to click on the exe to run the program. If possible, no side install. – JPFrancoia Jan 24 '15 at 14:49
  • I don't know how you installed Py2exe but you should use the installer from [here](http://sourceforge.net/projects/py2exe/files/py2exe/0.6.9/) for your appropriate version. – Malik Brahimi Jan 24 '15 at 15:18
  • I'm using the version 3.4, and I don't see it in the list. I install py2exe with pip. Does that matter ? The version from sourceforge does something more ? – JPFrancoia Jan 24 '15 at 16:33
  • Oh, I thought you were using Python 2.7. Anyway, look [here](https://pypi.python.org/pypi/py2exe/0.9.2.0#downloads). – Malik Brahimi Jan 24 '15 at 16:40
  • Ok, I installed py2exe that way. But now I get errors I don't get with the py2exe installed with pip. So really, what is the advantage to install py2exe from the website ? – JPFrancoia Jan 24 '15 at 17:13