Reputation: 2087
I am making an exe through py2exe using a python script. I had already gone through many examples of setup.py but none is working. I am using windows 7 64 bit and python 2.7.
from distutils.core import setup
import py2exe
import time
setup(
windows = [
{
"script": "myapp.py",
"icon_resources": [(1, "Windows.ico")]
}
],
)
time.sleep(2)
But dist produced through this setup.py contains myapp.exe with default exe image, not the icon I included. In cmd I am using python stup.py py2exe
Upvotes: 1
Views: 824
Reputation: 2710
I use py2exe through gui2exe and never had a problem with icon.
With gui2exe, you don't have to write setup.py and works great with py2exe, cx_freeze, etc.
You can get it here http://code.google.com/p/gui2exe/ And just start gui2exe.py by double clicking it (no installation required).
Upvotes: 0