[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: PyGTK, Debian and wrapping custom widgets.



Okay, the thing works now. But I had to alien RedHat's PYTHON. Not pygtk
or anything but Python. I obviously can't ask anyone to install RedHat's
python just to run my app, so does anyone have an idea where I can start
looking?

On Wed, Sep 27, 2000 at 10:14:13AM -0400, Danie Roux wrote:
> Hi all,
> 
> I don't think this is the right mailing list, but I frankly don't know
> where else to ask. This is debian/gtk/python related.
> 
> I wrote a custom widget in gtk (C). Wrapped it with PyGTK and it worked
> beautifully in RedHat. I've been using it a month now on RedHat.
> 
> I finally got Potato a few days back and have been struggling since. My
> custom, PyGTK wrapped widget core dumps when used from Python, but NOT
> when used in a C program (without the Python binding).
> 
> The core dump reveals that it is python (??) that crashed. Here is the
> relevant snippet of what happens:
> 
> static PyObject*
> wrap_dir_listing_new (PyObject *self, PyObject *args)
> {
>     GtkObject *tmp;
> 
>     if (!PyArg_ParseTuple (args, ":gtk_dir_listing_new"))
>         return NULL; /* If any arguments are sent, can't create object */
> 
>     /* To show that it is not my function that segfault */
>     tmp = (GtkObject *) gtk_dir_listing_new ();
>     /* tmp is not NULL */
> 
>     return PyGtk_New (tmp); // <--- This is where it segfaults
> }
> 
> I thought it was because an older PyGTK is on Potato than on Redhat 6.2
> but after installing the newer version it did not make a difference.
> 
> Another thing that bothered me. I had to put -lgtk -lglib and all that to
> LDSHARED in the Makefile before it would run without complaining about
> linker errors. This was not necessary on RedHat.
> 
> Could anybody please shed any light on this? I'm heading for a deadline
> and I don't want to re-install RedHat just to finish this.
> 
> Danie.
> 
> 
> -- 
> To UNSUBSCRIBE, email to debian-python-request@lists.debian.org
> with a subject of "unsubscribe". Trouble? Contact listmaster@lists.debian.org
> 



Reply to: