py2exe question

M

mitsura

Hi,

I just installed py2exe to create a binary of my Python script.
However, py2exe does not seem to create a binary from my .py script.
This is what I have done:
I create a setup.py script:
"
# setup.py
from distutils.core import setup
import py2exe

setup(name="APP1", scripts=["C:\\Python24\\_APP1.py"],)
"

I then ran "python setup.py py2exe"
I see a lot of stuff scrolling on the screen. A 'built' directory is
created. At the end I get a message saying that I may or may not need
to include some DLL (all windows system DLLs). and that's it. No error
message but also no binary.

When I remove 'scripts=["C:\\Python24\\_APP1.py"]' from the setup.py
file, I get exactly the same result. The same output, no error, no
binary.

Any idea what I am doing wrong here? Where should the compiled binary
go?

Any help much appreciated.

Kris
 
L

Larry Bates

Hi,

I just installed py2exe to create a binary of my Python script.
However, py2exe does not seem to create a binary from my .py script.
This is what I have done:
I create a setup.py script:
"
# setup.py
from distutils.core import setup
import py2exe

setup(name="APP1", scripts=["C:\\Python24\\_APP1.py"],)
"

I then ran "python setup.py py2exe"
I see a lot of stuff scrolling on the screen. A 'built' directory is
created. At the end I get a message saying that I may or may not need
to include some DLL (all windows system DLLs). and that's it. No error
message but also no binary.

When I remove 'scripts=["C:\\Python24\\_APP1.py"]' from the setup.py
file, I get exactly the same result. The same output, no error, no
binary.

Any idea what I am doing wrong here? Where should the compiled binary
go?

Any help much appreciated.

Kris
The .exe, library and .pyd files are written to /dist subdirectory
not /built (sic).

You setup file should look something like:

The .exe, library and .pyd files are written to /dist subdirectory
not /built (sic).

from distutils.core import setup
import py2exe
setup(name="APPI",
windows=[{"script":"_APPI.py"}],
# or console= for console app
version="1.50",
options={"py2exe": {"compressed": 1,
"optimize": 2,
"bundle_files":1}},
)

If that doesn't help, you may want to post to the py2exe
specific newsgroup at gmain.comp.python.py2exe.

-Larry Bates
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Similar Threads


Members online

Forum statistics

Threads
473,780
Messages
2,569,611
Members
45,278
Latest member
BuzzDefenderpro

Latest Threads

Top