Gui2Exe Problem Rename Executable

Hi Paulo,

        I am creating executable with Gui2Exe but the project have one name
example setup_application.py, I want to generate executable with
Aplication.exe, in the field of the Gui2Exe add Application but the
executable generate with setup_application.exe.
        If rename the executable project does not load.

There is an option in py2exe to change the executable name, and it is
called "dest_base". This option is currently not implemented in
GUI2Exe (although it would not be that complicated to add, I'll look
into it). What you could do at the moment (until I fix this missing
feature), is to export the setup file via the menus:

File => Export setup file

And then edit the generated file by editing the Target class adding
the "dest_base" keyword:

test_wx = Target(
    description = "A GUI app",
    script = filename,
    dest_base = "YOUR_EXECUTABLE_NAME")

Then, you just use the usual:

Python setup.py py2exe

I know this will not be saved in the GUI2Exe database, but I will fix
the problem as soon as I can.

Andrea.

"Imagination Is The Only Weapon In The War Against Reality."
http://xoomer.virgilio.it/infinity77/

···

On 4/11/07, Paulo Henrique Junqueira Amorim wrote:

Hi

I am having some problems running GUI2Exe on Linux. I have two machines: one with Fedora Core5, Python 2.4 and wxPython2.6 and another with SuSE 10.2, Python 2.5 and wxPython 2.8.

The main error I am getting is when importing wx.aui. Is there anything extra that I have to install in order to import it properly?

Traceback (most recent call last):
  File "GUI2Exe.py", line 16, in ?
    import wx.aui
ImportError: No module named aui

Cheers

Paulo

Paulo Nuin wrote:

Hi

I am having some problems running GUI2Exe on Linux. I have two machines: one with Fedora Core5, Python 2.4 and wxPython2.6 and another with SuSE 10.2, Python 2.5 and wxPython 2.8.

The main error I am getting is when importing wx.aui. Is there anything extra that I have to install in order to import it properly?

Traceback (most recent call last):
File "GUI2Exe.py", line 16, in ?
   import wx.aui
ImportError: No module named aui

Hi Paulo,

wx.aui was introduced somewhere in wx 2.7 so you would need at least that version but preferably 2.8. Andrea may be able to tell you a way to get around this if you only have 2.6. You could install a 2.8 version which you use only to run GUI2Exe to compile your 2.6 version, using wx.version to select it :slight_smile:

- Mike

Hi Paulo,

I am having some problems running GUI2Exe on Linux. I have two machines:
one with Fedora Core5, Python 2.4 and wxPython2.6 and another with SuSE
10.2, Python 2.5 and wxPython 2.8.

The main error I am getting is when importing wx.aui. Is there anything
extra that I have to install in order to import it properly?

Traceback (most recent call last):
File "GUI2Exe.py", line 16, in ?
   import wx.aui
ImportError: No module named aui

wx.aui has been added to wxPython in the 2.7 release, which means that
you Fedora Core5 will not have it installed (is a 2.6). It should
work, however, with you SuSE as it has wxPython 2.8.
Please keep in mind that GUI2Exe is still not usable on GTK platforms,
as the only compiler supported till now is py2exe, which works only on
Windows.

Andrea.

"Imagination Is The Only Weapon In The War Against Reality."
http://xoomer.virgilio.it/infinity77/

···

On 4/11/07, Paulo Nuin wrote:

Paulo Nuin wrote:

I tried packaging my application with py2app using a "simple" setup.py, but the resulting app was more than 70 Mb. What would be an ideal setup.py file in order to minimize a little bit the size of the resulting app?

What machine are you packaging on? A thread about this a while back seemed to indicate that for some reason, the .app ends up much bigger when built on an Intel machine than a PPC machine, even though both are building Universal apps. I suspect extra copies of some libs are being included or something.

Frank Niessink wrote:

I use hdiutil to create a dmg file, i.e. after python setup.py py2app I do:

a dmg is a good way to distribute, but you can also use just plain zip. In any case, you do need to bundle it up somehow, so you might as well compress.

the 47MB that MyApp.app is.

That's about the size I get too. I think 70 MB really is way too big. Please post to the macpython list about this.

Before doing that, you might want to put together a very simple sample you can post, and see what people get bundling it up on both Intel and PPC machines.

If ~40 MB is still too big, you may be able to remove some extra libs form you .app. Py2app tries to make things "just work" so it includes all of wxPython, etc. Py2app includes "recipes" to handle known complex packages like wx. You can look to see what it's doing, and you may be able to trim.

It's not going to get that much smaller though, between all the wx and wxPython libs and Intel and PPC binaries -- there's a LOT needed!

-Chris

···

--
Christopher Barker, Ph.D.
Oceanographer

Emergency Response Division
NOAA/NOS/OR&R (206) 526-6959 voice
7600 Sand Point Way NE (206) 526-6329 fax
Seattle, WA 98115 (206) 526-6317 main reception

Chris.Barker@noaa.gov