473,616 Members | 2,970 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

freeze.py and GTK apps

After freezing a PYGTK app, I am unable to run it. It this a common
problem, because I could not find any documentation on it at all.

I tried freezing this example, which gets by the make as well, but
running it results in a failure. This is on Ubuntu Linux:
http://www.moeraki.com/pygtktutorial.../helloworld.py

$ ./helloworld
Traceback (most recent call last):
File "helloworld.py" , line 7, in ?
import gtk
File "/usr/lib/python2.4/site-packages/gtk-2.0/gtk/__init__.py", line
37, in ? from _gtk import *
ImportError: No module named _gtk

Any suggestions?
--
Kristian Hermansen

Mar 28 '06 #1
2 2138
On Mon, 2006-03-27 at 16:15 -0800, kr************* ***@gmail.com wrote:
After freezing a PYGTK app, I am unable to run it. It this a common
problem, because I could not find any documentation on it at all.

I tried freezing this example, which gets by the make as well, but
running it results in a failure. This is on Ubuntu Linux:
http://www.moeraki.com/pygtktutorial.../helloworld.py

$ ./helloworld
Traceback (most recent call last):
File "helloworld.py" , line 7, in ?
import gtk
File "/usr/lib/python2.4/site-packages/gtk-2.0/gtk/__init__.py", line
37, in ? from _gtk import *
ImportError: No module named _gtk

Any suggestions?
--
Kristian Hermansen
From the freeze README


A warning about shared library modules
--------------------------------------

When your Python installation uses shared library modules such as
_tkinter.pyd, these will not be incorporated in the frozen program.
Again, the frozen program will work when you test it, but it won't
work when you ship it to a site without a Python installation.

Freeze prints a warning when this is the case at the end of the
freezing process:

Warning: unknown modules remain: ...

When this occurs, the best thing to do is usually to rebuild Python
using static linking only. Or use the approach described in the previous
section to declare a library path using sys.path, and place the modules
such as _tkinter.pyd there.

Same applies here ...

Mar 28 '06 #2
On 3/28/06, Adam DePrince <ad***********@ gmail.com> wrote:
When your Python installation uses shared library modules such as
_tkinter.pyd, these will not be incorporated in the frozen program.
Again, the frozen program will work when you test it, but it won't
work when you ship it to a site without a Python installation.
No, it didn't even run!!! So, it won't run frozen on ANY system. The
_gtk import choked the whole program and it died with exit status ==
1. So, even though I did have the GTK libraries locally, the program
exited improperly. The unfrozen script ran fine, so isn't this a
different problem entirely?
Freeze prints a warning when this is the case at the end of the
freezing process:

Warning: unknown modules remain: ...

When this occurs, the best thing to do is usually to rebuild Python
using static linking only. Or use the approach described in the previous
section to declare a library path using sys.path, and place the modules
such as _tkinter.pyd there.

Same applies here ...


Well, what we want is a totally static frozen build, but if not
possible (GTK is huge right?), GTK is assumed to be on the target
machine. However, the frozen binary still doesn't run properly. Any
suggestions? Try freezing the example code yourself and running it,
perhaps I am doing something amazingly wrong here...
--
Kristian Hermansen
Mar 28 '06 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

2
1899
by: aww91 | last post by:
Company is planning a Sybase to UDB migration that is projected to take 1 year. During that long period of time any Code Freeze put into place would impact our users (we normally release code changes once a month). Any suggestions on how to manage a partial code freeze while under going a major migration like this one?
11
2760
by: Timothy Shih | last post by:
Hi, I am having a freezing issue with my application. My application serves several remotable objects, all of which must be initialized before their use. Furthermore, some of them depend on each other. On my application startup, I configure the objects usting the RemotingConfiguration class to load the config file. Then I "ping" each of the objects to call their constructors. This all works fine if no one is attempting to connect at the...
4
13840
by: Roger Withnell | last post by:
I would like to freeze column and row headings on a webpage, simulating freeze panes as in an Excel spreadsheet. Don't seem to be able to do it with Frames. Is there a way with Javascript and/or CSS and or Frames? Thanks in anticipation.
2
1986
by: paraidy | last post by:
Hi all, i would to know how is possible to freeze another process from my application and unfreeze it, can someone help me? thx all.
1
1390
by: kdpo1990 | last post by:
I've worked with ASP.NET apps. for a long time, but now, i have to figure out how to do same in win app. I need to find a way to lock or freeze table column in datagrid. This is a link to an article explaining on how to do this in HTML: http://web.tampabay.rr.com/bmerkey/examples/locked-column-csv.html Thanks
1
3176
by: jmalone | last post by:
I have a python script that I need to freeze on AIX 5.1 (customer has AIX and does not want to install Python). The python script is pretty simple (the only things it imports are sys and socket). The README file in the Tools/freeze directory of the Python-2.4.4 distribution says the following (and many other things): Previous versions of Freeze used a pretty simple-minded algorithm to
1
2458
by: Cameron Laird | last post by:
How is Freeze--freeze.py <URL: http://wiki.python.org/moin/Freeze >--packaged for Debian? *Is* it packaged for Debian?
4
7021
by: ToxSox | last post by:
Hello. This is my first post here and i have a big problem with my script! One page (child.htm), was delivered not by me and i can't change it. This page calls a methode in a object of my page. I have opened the child.htm in a popup, so by opener.API the child.htm page can user the methodes which was defined in my API Obnject on (parent.htm). On my parent.htm, with i can edit, the called methode "sendValue" open a sync HTTPRequest and will...
2
2640
by: Gabriel Rossetti | last post by:
Hello everyone, I'm trying to use python's freeze utility but I'm running into problems. I called it like this : python /usr/share/doc/python2.5/examples/Tools/freeze/freeze.py ~/Documents/Code/Python/src/jester/service.py -m jester then I did : make
0
8146
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
8647
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
8592
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
0
8449
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
7121
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
0
4063
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
4141
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
2579
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
0
1445
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.