Title: Samsung Enterprise Portal mySingle

Hi.

I also had a same problem. But now I know why this problem is happened.

I think the problem is there's no impl(GdkWindowImplDirectFB) object in _gdk_windowing_window_init().

So when you refer impl pointer, there's some segmentation fault.

 

In _gdk_windowing_window_init().

{

    ...

  _gdk_parent_root = g_object_new (GDK_TYPE_WINDOW, NULL);

  private = GDK_WINDOW_OBJECT (_gdk_parent_root);

  impl = GDK_WINDOW_IMPL_DIRECTFB (private->impl);

  impl->gdkWindow      = _gdk_parent_root;

  ...

}

 

In my case, I declare GdkWindowImplDirectFB info using G_DEFINE_TYPE_WITH_CODE.

And initialize impl data.

impl = g_object_new(_gdk_window_impl_get_type(), NULL );

 

Maybe it should be added in _gdk_windowing_window_init(), gdk_directfb_window_new(), gdk_directfb_create_child_window(), gdk_window_foreign_new_for_display().

After that, gtk-demo will be worked correctly.

 

BR

minsu.han

 

 


----------------------------------------------------------------------

Message: 1
Date: Mon, 5 Jan 2009 17:27:56 +0530
From: "Dhananjoy Chutia" <dha...@gmail.com>
Subject: [directfb-dev] Unable to run gtk-demo for gtk+-2.14.6 with
    DirectFB    : help!!!!!!!!!!!!!!!
To: directfb-dev@directfb.org
Message-ID:
    <ff1c2bd40901050357k40f68319j46d50d5756078...@mail.gmail.com>
Content-Type: text/plain; charset="utf-8"

Hi,
  gtk+-2.14.6 compilation was failed for arm-linux with directfb. I had
compiled gtk+-2.14.6 with configure option --with-gdktarget=directfb
--without-x --disable-gdiplus --without-libtiff --disable-gtk-doc
--disable-man --disable-glibtest --without-libjasper. It is to be noted that
glib version is glib-2.18.3, directfb version is 1.2.0.

Then, I applied the patch available in the link:
http://bugzilla.gnome.org/attachment.cgi?id=122159&action=""

The compilation broke even after that, so the following change as per the
patch was reverted back in the file:
gtk+-2.14.6/gdk/directfb/gdkwindow-directfb.c
directfb/gdkwindow-directfb.c

@@ -99,7 +114,6 @@
  while (tmp_list)
    {
      GdkWindowObject       *private = GDK_WINDOW_OBJECT( tmp_list->data );
-      GdkWindowImplDirectFB *wimpl   = GDK_WINDOW_IMPL_DIRECTFB(
private->impl );

      if (private->update_freeze_count)
        {

Ultimately, compiled well.

But, when I run gtk-demo provided with the package, in the target device the
application crashes, showing Segmentation fault.

Here is the back trace...........

(gdb) bt
#0  _gdk_windowing_window_init () at gdkwindow-directfb.c:432
#1  0x40072d7c in IA__gdk_display_open (display_name=0x45020 "?<\004") at
gdkdisplay-directfb.c:136
#2  0x4004f6a4 in IA__gdk_display_open_default_libgtk_only () at gdk.c:291
#3  0x401da954 in IA__gtk_init_check (argc=0x45020, argv=0x1) at
gtkmain.c:952
#4  0x401da970 in IA__gtk_init (argc=0x45020, argv=0x1) at gtkmain.c:987
#5  0x0001ddc8 in main (argc=1, argv=0xbebd6d34) at main.c:949
(gdb) bt'
#0  _gdk_windowing_window_init () at gdkwindow-directfb.c:432
       desc = {flags = 3200084968, caps = 1073785796, width = 1073772224,
height = 0, pixelformat = 1, posx = 1, posy = 0,
 surface_caps = 1083299516, parent_id = 1074498404, options = DWOP_NONE,
stacking = 1074498328, resource_id = 210500}
       impl = (GdkWindowImplDirectFB *) 0x0
       dlc = {flags = 15, width = 720, height = 480, pixelformat =
DSPF_RGB16, buffermode = DLBM_BACKSYSTEM,
 options = DLOP_NONE, source = 0, surface_caps = DSCAPS_NONE}
       __PRETTY_FUNCTION__ = "_gdk_windowing_window_init"
#1  0x40072d7c in IA__gdk_display_open (display_name=0x45020 "?<\004") at
gdkdisplay-directfb.c:136
       ret = DFB_OK
       directfb = (IDirectFB *) 0x3f740
       layer = (IDirectFBDisplayLayer *) 0x410d8
       keyboard = (IDirectFBInputDevice *) 0x41218
       argc = 0
       argv = (char **) 0x0
#2  0x4004f6a4 in IA__gdk_display_open_default_libgtk_only () at gdk.c:291
       display = (GdkDisplay *) 0x0
       __PRETTY_FUNCTION__ = "IA__gdk_display_open_default_libgtk_only"
#3  0x401da954 in IA__gtk_init_check (argc=0x45020, argv=0x1) at
gtkmain.c:952
No locals.
#4  0x401da970 in IA__gtk_init (argc=0x45020, argv=0x1) at gtkmain.c:987
No locals.
#5  0x0001ddc8 in main (argc=1, argv=0xbebd6d34) at main.c:949
       window = (GtkWidget *) 0x40821e24
       notebook = (GtkWidget *) 0x1
       hbox = (GtkWidget *) 0x1


As, per my observation, the application is unable to initialize the
window....
Can anyone help me to work with gtk with directfb backend.........?

Regards
Dhananjoy
-------------- next part --------------

 

_______________________________________________
directfb-dev mailing list
directfb-dev@directfb.org
http://mail.directfb.org/cgi-bin/mailman/listinfo/directfb-dev

Reply via email to