Making small executive file for distribution

M

Marin Brkic

Not commercial distribution, but an academic kind of sorts - giving
the exe file to coleagues, so they can use it in their work. Giving
..py file is not an option, since due to centralized computer
maintenance, they don't (and cannot) have installed python (except the
ones that bring their own computer at work, but those are an
exception).

As far as I know py2exe is the only option which can do such a thing
(make exe files from scripts). Is there a way to make those exe files
a little smaller (for a small script they easily go up to 5-10 mb).

Has anyone had a situation like this ? All your inputs and suggestions
are more then welcomed.
 
M

mdsherry

Not commercial distribution, but an academic kind of sorts - giving
the exe file to coleagues, so they can use it in their work. Giving
.py file is not an option, since due to centralized computer
maintenance, they don't (and cannot) have installed python (except the
ones that bring their own computer at work, but those are an
exception).

As far as I know py2exe is the only option which can do such a thing
(make exe files from scripts). Is there a way to make those exe files
a little smaller (for a small script they easily go up to 5-10 mb).

Has anyone had a situation like this ? All your inputs and suggestions
are more then welcomed.

If you don't create a monolithic EXE, then most of the extra files
(that make up the bulk of the size) can be shared between other
converted scripts. That is, if you convert foo.py, and send the bundle
to your colleague, then convert bar.py, you only need to send bar.exe,
and it will run fine if they execute it in the same directory that has
all the DLLs you sent with foo.exe.

Another option might be to encourage them to download Portable Python,
which doesn't need to be installed.

Mark Sherry
 
M

Mike Driscoll

Not commercial distribution, but an academic kind of sorts - giving
the exe file to coleagues, so they can use it in their work. Giving
.py file is not an option, since due to centralized computer
maintenance, they don't (and cannot) have installed python (except the
ones that bring their own computer at work, but those are an
exception).

As far as I know py2exe is the only option which can do such a thing
(make exe files from scripts). Is there a way to make those exe files
a little smaller (for a small script they easily go up to 5-10 mb).

Has anyone had a situation like this ? All your inputs and suggestions
are more then welcomed.

It ends up being so large because of the dlls that are needed. There
are other ways to distribute programs listed here:

http://www.freehackers.org/Packaging_a_python_program

Mike
 
M

Marin Brkic

If you don't create a monolithic EXE, then most of the extra files
(that make up the bulk of the size) can be shared between other
converted scripts. That is, if you convert foo.py, and send the bundle
to your colleague, then convert bar.py, you only need to send bar.exe,
and it will run fine if they execute it in the same directory that has
all the DLLs you sent with foo.exe.

Another option might be to encourage them to download Portable Python,
which doesn't need to be installed.

This is an interesting suggestion. I didn't know there was a portable
version of python. I will look into it - could just turn out to be the
perfect solution to this (after all, it would be even simpler if they
could send/receive just .py script).

Thank you.
 
S

sturlamolden

Has anyone had a situation like this ? All your inputs and suggestions
are more then welcomed.

Send them the .py file and confirm that it does work. The lack of
Python can be blamed on the incompetent BOFH. Chances are the
situation will change when the BOFH gets 20 requests for Python a
day.
 
M

Marin Brkic

Send them the .py file and confirm that it does work. The lack of
Python can be blamed on the incompetent BOFH. Chances are the
situation will change when the BOFH gets 20 requests for Python a
day.

Yes, I agree. But in large institutions, where system engineers
maintain a lot of computers there usually exists a policy on what is
installed on computers and what is not. And currently python is not.
And it's not gonna change anytime soon since only few of us are using
it (2 of us use it on personal laptops, to others we send exe files).
 
L

Larry Bates

Marin said:
Not commercial distribution, but an academic kind of sorts - giving
the exe file to coleagues, so they can use it in their work. Giving
.py file is not an option, since due to centralized computer
maintenance, they don't (and cannot) have installed python (except the
ones that bring their own computer at work, but those are an
exception).

As far as I know py2exe is the only option which can do such a thing
(make exe files from scripts). Is there a way to make those exe files
a little smaller (for a small script they easily go up to 5-10 mb).

Has anyone had a situation like this ? All your inputs and suggestions
are more then welcomed.

Times have changed, 5-10Mb is REALLY small. Flash drives hold 4000-8000Mb
for less than $20 and standard hard drives are now 500Gb. IMHO you are
concerned about a problem that doesn't actually exist.

-Larry
 

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

Members online

No members online now.

Forum statistics

Threads
473,997
Messages
2,570,241
Members
46,831
Latest member
RusselWill

Latest Threads

Top