wxPRE initial test

Hi all

An initial version of wxPRE is available for Windows (done by me and Stephen Emslie)
This is mainly to demonstrate the progress made so far, its very simple
Basically we have a wxPRE.py script, which runs the first script on the command line and passes it any other options.
It also does manual checking for .pth files, which are not handled by py2exe-generated executables.
There is also a simple setup.py for making wxPRE.exe using py2exe
The result is an executable which can be used as a substitue for python for running wx-based python programs
Extra modules can be included through the use of .pth files

Any comments appreciated, but please be aware this is just a tester....
http://davidf.sjsoft.com/files/wxPRE-0.1-src.zip (the source, < 1k)
http://davidf.sjsoft.com/files/wxPRE-0.1-py2exe.zip (the compiled version, about 7MB)

David

David Fraser wrote:

Hi all

An initial version of wxPRE is available for Windows (done by me and Stephen Emslie)
This is mainly to demonstrate the progress made so far, its very simple
Basically we have a wxPRE.py script, which runs the first script on the command line and passes it any other options.
It also does manual checking for .pth files, which are not handled by py2exe-generated executables.
There is also a simple setup.py for making wxPRE.exe using py2exe
The result is an executable which can be used as a substitue for python for running wx-based python programs
Extra modules can be included through the use of .pth files

Any comments appreciated, but please be aware this is just a tester....
http://davidf.sjsoft.com/files/wxPRE-0.1-src.zip (the source, < 1k)
http://davidf.sjsoft.com/files/wxPRE-0.1-py2exe.zip (the compiled version, about 7MB)

Nice start!

You may want to put the py2exe options needed to include all the extra modules and packages within the setup.py file so people don't have to be familiar with the py2exe command-line options.

···

--
Robin Dunn
Software Craftsman
http://wxPython.org Java give you jitters? Relax with wxPython!

Robin Dunn wrote:

David Fraser wrote:

Hi all

An initial version of wxPRE is available for Windows (done by me and Stephen Emslie)
This is mainly to demonstrate the progress made so far, its very simple
Basically we have a wxPRE.py script, which runs the first script on the command line and passes it any other options.
It also does manual checking for .pth files, which are not handled by py2exe-generated executables.
There is also a simple setup.py for making wxPRE.exe using py2exe
The result is an executable which can be used as a substitue for python for running wx-based python programs
Extra modules can be included through the use of .pth files

Any comments appreciated, but please be aware this is just a tester....
http://davidf.sjsoft.com/files/wxPRE-0.1-src.zip (the source, < 1k)
http://davidf.sjsoft.com/files/wxPRE-0.1-py2exe.zip (the compiled version, about 7MB)

Nice start!

You may want to put the py2exe options needed to include all the extra modules and packages within the setup.py file so people don't have to be familiar with the py2exe command-line options.

Yes, I've just found out how to do this.
I've updated py2exe as well to create an installer using InnoSetup
I've also tested it to work with wx 2.4 as well as wx 2.5
The resulting files are here:
http://davidf.sjsoft.com/files/wxPRE-0.2-src.zip (the source, < 5k)
http://davidf.sjsoft.com/files/wxPRE-0.2-src.tar.gz (the source, < 5k)
http://davidf.sjsoft.com/files/wxPRE-0.2-wx2.4.2.4-setup.exe (installer with wx2.4.2.4, 6.7MB)
http://davidf.sjsoft.com/files/wxPRE-0.2-wx2.5.1.5-setup.exe (installer with wx2.4.2.4, 7.6MB)

So the next steps are:
- add info to the registry about each wxPRE installation
- add ability to package wxPRE apps, with or without wxPRE
- add ability to associate wxPRE apps with wxPRE (depends on packaging)

David

David Fraser <davidf@sjsoft.com> writes:

Robin Dunn wrote:

Nice start!

You may want to put the py2exe options needed to include all the
extra modules and packages within the setup.py file so people don't
have to be familiar with the py2exe command-line options.

Yes, I've just found out how to do this.
I've updated py2exe as well to create an installer using InnoSetup
I've also tested it to work with wx 2.4 as well as wx 2.5
The resulting files are here:
http://davidf.sjsoft.com/files/wxPRE-0.2-src.zip (the source, < 5k)

File not found on server.

http://davidf.sjsoft.com/files/wxPRE-0.2-src.tar.gz (the source, < 5k)

File not found on server.

http://davidf.sjsoft.com/files/wxPRE-0.2-wx2.4.2.4-setup.exe
(installer with wx2.4.2.4, 6.7MB)

I downloaded this, and noticed that these dlls are also included:
  DDRAW.dll GLU32.dll OPENGL32.dll

That is really py2exe's fault, but it should be avoided. First, I'm not
sure if they are redistributable (you should check the license).
Second, AFAIK, they are part of the system, and must be installed from
official MS installers (if they are not already present) - they will
most certainly not work on some windows versions.

py2exe in CVS already should be fixed to exlude them.

http://davidf.sjsoft.com/files/wxPRE-0.2-wx2.5.1.5-setup.exe
(installer with wx2.4.2.4, 7.6MB)

So the next steps are:
- add info to the registry about each wxPRE installation
- add ability to package wxPRE apps, with or without wxPRE
- add ability to associate wxPRE apps with wxPRE (depends on packaging)

David

Thomas

Thomas Heller wrote:

David Fraser <davidf@sjsoft.com> writes:

Robin Dunn wrote:

Nice start!

You may want to put the py2exe options needed to include all the
extra modules and packages within the setup.py file so people don't
have to be familiar with the py2exe command-line options.

Yes, I've just found out how to do this.
I've updated py2exe as well to create an installer using InnoSetup
I've also tested it to work with wx 2.4 as well as wx 2.5
The resulting files are here:
http://davidf.sjsoft.com/files/wxPRE-0.2-src.zip (the source, < 5k)
   

File not found on server.

http://davidf.sjsoft.com/files/wxPRE-0.2-src.tar.gz (the source, < 5k)
   

File not found on server.

Sorry, my bad, there now, promise to check next time ...

http://davidf.sjsoft.com/files/wxPRE-0.2-wx2.4.2.4-setup.exe
(installer with wx2.4.2.4, 6.7MB)
   

I downloaded this, and noticed that these dlls are also included:
DDRAW.dll GLU32.dll OPENGL32.dll

That is really py2exe's fault, but it should be avoided. First, I'm not
sure if they are redistributable (you should check the license).
Second, AFAIK, they are part of the system, and must be installed from
official MS installers (if they are not already present) - they will
most certainly not work on some windows versions.

Thanks for pointing this out...

py2exe in CVS already should be fixed to exlude them.

Unfortunately it's impossible to get access to py2exe CVS anonymously at the moment (sourceforge problem) ... is there a way I can get hold of the patch?

Thanks for the feedback

David

Hello,

I'm working on a little program that display images, but i want to put an image png in the code, in the wxdemo i have found a png converted to stream (see example after), and with a function this stream is reconverted in image.

My question is, starting with a png, how to create stream?
Thanks a lot

Whamoo

(example of stream):

cross_png = \
'\x89PNG\r\n\x1a\n\x00\x00\x00\rIHDR\x00\x00\x00 \x00\x00\x00 \x08\x06\x00\
\x00\x00szz\xf4\x00\x00\x00\x04sBIT\x08\x08\x08\x08|\x08d\x88\x00\x00\x03\
\x9fIDATx\x9c\xc5\x97OH*_\x14\xc7\xbfW~\x82\x8c\x19Sh\xc2\x80\x8b\xfe\x10\
\x04A\x90P.\x84(r\x13ER\x14\x11\x18A\x11\x14\xba0\n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8\xc8\xf2\
\xf9<\xb5\xb5\xb5!\x93\xc9\xe0\xf3\xf3\x13ccc\xd0\xe9tx}}\x85\xc3\xe1\xc0\
\xea\xea\xaa\xac5\xb3\xeae2\x91H\xa0T*\xa1R\xa9|\xc14:X\xce\xcf\xcf\x89\x88\
\xb0\xbe\xbe\xaez\x16|]H.//\xe9\xe5\xe5\x05\x8f\x8f\x8f8::\x02\x00loo#\x1a\
\x8d6\xf5F\xd40@5\xf2\xf9<\xdd\xdd\xdd\x01\x00\xacVk\xd3\xafdM\x03\xfc\xed\
\xf8\x01\xe9\t\x94\x8c\xa7\xf9\xf9<\x00\x00\x00\x00IEND\xaeB`\x82'

In the tools folder use img2py.py
This link may be of some help:

http://wiki.wxpython.org/index.cgi/Frequently_20Asked_20Questions#head-330925f16ac88f957e0b6f7d71faa1ad2d009e5b

whamoo wrote:

···

Hello,

I'm working on a little program that display images, but i want to put an image png in the code, in the wxdemo i have found a png converted to stream (see example after), and with a function this stream is reconverted in image.

My question is, starting with a png, how to create stream?
Thanks a lot

Whamoo

(example of stream):

Thomas Heller wrote:

David Fraser <davidf@sjsoft.com> writes:

Robin Dunn wrote:

Nice start!

You may want to put the py2exe options needed to include all the
extra modules and packages within the setup.py file so people don't
have to be familiar with the py2exe command-line options.

Yes, I've just found out how to do this.
I've updated py2exe as well to create an installer using InnoSetup
I've also tested it to work with wx 2.4 as well as wx 2.5
The resulting files are here:
http://davidf.sjsoft.com/files/wxPRE-0.2-src.zip (the source, < 5k)
   

File not found on server.

http://davidf.sjsoft.com/files/wxPRE-0.2-src.tar.gz (the source, < 5k)
   

File not found on server.

http://davidf.sjsoft.com/files/wxPRE-0.2-wx2.4.2.4-setup.exe
(installer with wx2.4.2.4, 6.7MB)
   

I downloaded this, and noticed that these dlls are also included:
DDRAW.dll GLU32.dll OPENGL32.dll

That is really py2exe's fault, but it should be avoided. First, I'm not
sure if they are redistributable (you should check the license).
Second, AFAIK, they are part of the system, and must be installed from
official MS installers (if they are not already present) - they will
most certainly not work on some windows versions.

py2exe in CVS already should be fixed to exlude them.

OK, sourceforge cvs is back up, I have grabbed py2exe from there and rebuilt, and the DLLs are no longer there.
This drops the file size by another 900k. The only dlls remaining are python23, pythoncom23, pywintypes23, and the wx dlls.
Also I have updated the path code to handle multi-line path files as Jean-Michel Fauth suggested.
New (real working :-)) URLs below.

David
PS Thomas, the new mingw support in py2exe seems to work fine, are you planning a release?

http://davidf.sjsoft.com/files/wxPRE-0.2.1-wx2.4.2.4-setup.exe

http://davidf.sjsoft.com/files/wxPRE-0.2.1-wx2.5.1.5-setup.exe

http://davidf.sjsoft.com/files/wxPRE-0.2.1.tar.gz

http://davidf.sjsoft.com/files/wxPRE-0.2.1.zip

David Fraser <davidf@sjsoft.com> writes:

PS Thomas, the new mingw support in py2exe seems to work fine, are you
planning a release?

Yes, later this week.

Thomas