[Anjuta-list] Grave problem with the debugger



I have a grave problem with the debugger.

After several trials, I end to include the source of my "open_file" method directly into the main source code to see if I succeed in debugging it.
But, hey, the debugger simply doesn't work!
I try to summarize the steps I made to understand where is my fault or if there is a bug.

This is the source code of the main method.

int main (int argc, char *argv[])
{
   GtkWidget *main_window;
   GtkWidget *view;
   GtkTextBuffer *buffer;
   gchar **contents;
   gsize *length;
   GError **error;
#ifdef ENABLE_NLS
       bindtextdomain (GETTEXT_PACKAGE, PACKAGE_LOCALE_DIR);
       textdomain (PACKAGE);
   #endif
gnome_init (PACKAGE, VERSION, argc, argv);
   glade_gnome_init ();
   set_glade_xml(); //load the xml in the glade_xml global variable
view = glade_xml_get_widget (glade_xml, "textviewsource");
   buffer = gtk_text_view_get_buffer (GTK_TEXT_VIEW (view));
   //pick a random file (autogen.sh) to test the method
if (g_file_get_contents("home/mickymouse/Projects/pdg/autogen.sh", contents, length, error)) {
       buffer = gtk_text_view_get_buffer (GTK_TEXT_VIEW (view));
       gtk_text_buffer_set_text (buffer, *contents, -1);;
   } else {
       gtk_text_buffer_set_text (buffer, "some string here", -1);
   };
/*
    * The .glade filename should be on the next line.
    */
   //comment the next line: use the global variable glade_xml instead
   //xml = glade_xml_new (PACKAGE_SOURCE_DIR"/pdg.glade", NULL, NULL);

   /* This is important */
   glade_xml_signal_autoconnect (glade_xml);
   main_window = glade_xml_get_widget (glade_xml, "main_window");
   gtk_widget_show (main_window);

   gtk_main ();
   return 0;
}

1) Close and reopen Anjuta. Open my pdg project.
2) Checked in the compiler setting that there are'nt any optimazation and that the debug flag is checked.
3) Shift +F11 to rebuild all.
4) Start the debugger. The debug toolbar now is active.
5) Click in the debug toolbar the "Step Only one istruction" button
6) The terminal windows is open. I click in the window Anjuta to bring it to the front.
7) The debug toolbar now is disabled.

The same result is if I set a breakpoint in any line of code and launch the debugger with F4. The debugger correctly stop at the breakpoint but the debug toolbar is compitely disabled.

I'm using ubuntu 5.10, on amd64 architecture.

Before i come crazy can anyone give me some hint?

ciao, Michele




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