C/C++
Von: Alexander, 15.8.2004 21:34 Uhr
Hallo...

Wenn ich versuche, den hierunter stehenden Quelltext zu übersetzen, dann bekomme ich immer Meldungen über eine Unzahl von Fehlern in den Gtk+ 2.0 Bibliotheken.

Ich nutze im Augenblick gcc 3.3.3 der Distri Fedora Core 2. Der Fehler ist allerdings auch schon unter Mandrake 10.0 aufgetreten.

Mittlerweile habe ich's aufgegeben, auch nur einen Quelltext zu schreiben, in dem die gtk.h eingebunden wird; bei hallowelt.c mit gtk.h Include treten die Fehler bereits auf.

Ich nutze die gtk Bibliothek in der Version 2.2.4. Ich habe unter /usr/include einen Symlink namens 'gtk' auf '/usr/include/gtk+-2.0/gtk' und einen namens gdk auf '/usr/include/gtk+-2.0/gdk'

Kleiner Beispielquelltext (soll eigentlich nichts machen, sondern nur durchkompilieren!)

#include <gtk/gtk.h>

#define WID GtkWidget

void killall();

int main(int argc, char *argv[])
{
	WID p_MainWindow;
	gtk_init(&argc, argv);
	
	p_MainWindow = gtk_window_new(GTK_WINDOW_TOPLEVEL);
	gtk_signal_connect(GTK_OBJECT(hauptfenster), "destroy", GTK_SIGNAL_FUNC(killall), NULL);
	
	gtk_main();
}

void killall()
{
	gtk_main_quit();
}


Ab hier unten dann der letzte Rest der gcc-Ausgabe (alles was in die xterm History passte):

/usr/include/gtk/gtktextiter.h:224: error: `gtk_text_iter_backward_visible_cursor_positions' declared as function returning a function
/usr/include/gtk/gtktextiter.h:236: error: `gtk_text_iter_forward_to_line_end' declared as function returning a function
/usr/include/gtk/gtktextiter.h:248: error: `gtk_text_iter_forward_to_tag_toggle' declared as function returning a function
/usr/include/gtk/gtktextiter.h:251: error: `gtk_text_iter_backward_to_tag_toggle' declared as function returning a function
/usr/include/gtk/gtktextiter.h:253: error: Syntaxfehler before "ch"
/usr/include/gtk/gtktextiter.h:253: error: `GtkTextCharPredicate' declared as function returning a function
/usr/include/gtk/gtktextiter.h:257: error: Syntaxfehler before "gpointer"
/usr/include/gtk/gtktextiter.h:258: error: `gtk_text_iter_forward_find_char' declared as function returning a function
/usr/include/gtk/gtktextiter.h:261: error: Syntaxfehler before "gpointer"
/usr/include/gtk/gtktextiter.h:262: error: `gtk_text_iter_backward_find_char' declared as function returning a function
/usr/include/gtk/gtktextiter.h:265: error: Syntaxfehler before '*' token
/usr/include/gtk/gtktextiter.h:269: error: `gtk_text_iter_forward_search' declared as function returning a function
/usr/include/gtk/gtktextiter.h:272: error: Syntaxfehler before '*' token
/usr/include/gtk/gtktextiter.h:276: error: `gtk_text_iter_backward_search' declared as function returning a function
/usr/include/gtk/gtktextiter.h:283: error: `gtk_text_iter_equal' declared as function returning a function
/usr/include/gtk/gtktextiter.h:285: error: `gtk_text_iter_compare' declared as function returning a function
/usr/include/gtk/gtktextiter.h:288: error: `gtk_text_iter_in_range' declared as function returning a function
In file included from /usr/include/gtk/gtktextbuffer.h:34,
                 from /usr/include/gtk/gtk.h:150,
                 from hallo4.c:1:
/usr/include/gtk/gtktextmark.h:71: error: Syntaxfehler before "GObject"
/usr/include/gtk/gtktextmark.h:78: error: Syntaxfehler before "GObjectClass"
/usr/include/gtk/gtktextmark.h:85: error: Syntaxfehler before '}' token
/usr/include/gtk/gtktextmark.h:87: error: Syntaxfehler before "gtk_text_mark_get_type"
/usr/include/gtk/gtktextmark.h:87: error: Syntaxfehler before "G_GNUC_CONST"
/usr/include/gtk/gtktextmark.h:91: error: `gtk_text_mark_get_visible' declared as function returning a function
/usr/include/gtk/gtktextmark.h:93: error: Syntaxfehler before "gchar"
/usr/include/gtk/gtktextmark.h:94: error: `gtk_text_mark_get_deleted' declared as function returning a function
/usr/include/gtk/gtktextmark.h:96: error: `gtk_text_mark_get_left_gravity' declared as function returning a function
In file included from /usr/include/gtk/gtk.h:150,
                 from hallo4.c:1:
/usr/include/gtk/gtktextbuffer.h:61: error: Syntaxfehler before "GObject"
/usr/include/gtk/gtktextbuffer.h:66: error: Syntaxfehler before '*' token
/usr/include/gtk/gtktextbuffer.h:67: error: Syntaxfehler before '*' token
/usr/include/gtk/gtktextbuffer.h:71: error: Syntaxfehler before "user_action_count"
/usr/include/gtk/gtktextbuffer.h:74: error: Syntaxfehler before "modified"
/usr/include/gtk/gtktextbuffer.h:79: error: Syntaxfehler before "GObjectClass"
/usr/include/gtk/gtktextbuffer.h:83: error: Syntaxfehler before '*' token
/usr/include/gtk/gtktextbuffer.h:88: error: Syntaxfehler before "GdkPixbuf"
/usr/include/gtk/gtktextbuffer.h:101: error: conflicting types for `changed'
/usr/include/gtk/gtkicontheme.h:55: error: previous declaration of `changed'
/usr/include/gtk/gtktextbuffer.h:136: error: Syntaxfehler before '}' token
/usr/include/gtk/gtktextbuffer.h:138: error: Syntaxfehler before "gtk_text_buffer_get_type"
/usr/include/gtk/gtktextbuffer.h:138: error: Syntaxfehler before "G_GNUC_CONST"
/usr/include/gtk/gtktextbuffer.h:144: error: `gtk_text_buffer_get_line_count' declared as function returning a function
/usr/include/gtk/gtktextbuffer.h:145: error: `gtk_text_buffer_get_char_count' declared as function returning a function
/usr/include/gtk/gtktextbuffer.h:152: error: Syntaxfehler before '*' token
/usr/include/gtk/gtktextbuffer.h:158: error: Syntaxfehler before '*' token
/usr/include/gtk/gtktextbuffer.h:161: error: Syntaxfehler before '*' token
/usr/include/gtk/gtktextbuffer.h:166: error: Syntaxfehler before '*' token
/usr/include/gtk/gtktextbuffer.h:168: error: `gtk_text_buffer_insert_interactive' declared as function returning a function
/usr/include/gtk/gtktextbuffer.h:170: error: Syntaxfehler before '*' token
/usr/include/gtk/gtktextbuffer.h:172: error: `gtk_text_buffer_insert_interactive_at_cursor' declared as function returning a function
/usr/include/gtk/gtktextbuffer.h:182: error: `gtk_text_buffer_insert_range_interactive' declared as function returning a function
/usr/include/gtk/gtktextbuffer.h:186: error: Syntaxfehler before '*' token
/usr/include/gtk/gtktextbuffer.h:193: error: Syntaxfehler before '*' token
/usr/include/gtk/gtktextbuffer.h:205: error: `gtk_text_buffer_delete_interactive' declared as function returning a function
/usr/include/gtk/gtktextbuffer.h:210: error: Syntaxfehler before '*' token
/usr/include/gtk/gtktextbuffer.h:215: error: Syntaxfehler before '*' token
/usr/include/gtk/gtktextbuffer.h:223: error: Syntaxfehler before "GdkPixbuf"
/usr/include/gtk/gtktextbuffer.h:236: error: Syntaxfehler before '*' token
/usr/include/gtk/gtktextbuffer.h:245: error: Syntaxfehler before '*' token
/usr/include/gtk/gtktextbuffer.h:248: error: Syntaxfehler before '*' token
/usr/include/gtk/gtktextbuffer.h:251: error: Syntaxfehler before '*' token
/usr/include/gtk/gtktextbuffer.h:275: error: Syntaxfehler before '*' token
/usr/include/gtk/gtktextbuffer.h:279: error: Syntaxfehler before '*' token
/usr/include/gtk/gtktextbuffer.h:291: error: Syntaxfehler before '*' token
/usr/include/gtk/gtktextbuffer.h:336: error: `gtk_text_buffer_get_modified' declared as function returning a function
/usr/include/gtk/gtktextbuffer.h:357: error: `gtk_text_buffer_get_selection_bounds' declared as function returning a function
/usr/include/gtk/gtktextbuffer.h:360: error: `gtk_text_buffer_delete_selection' declared as function returning a function
/usr/include/gtk/gtktextbuffer.h:371: error: Syntaxfehler before '*' token
In file included from /usr/include/gtk/gtk.h:151,
                 from hallo4.c:1:
/usr/include/gtk/gtktextview.h:68: error: field `parent_instance' has incomplete type
/usr/include/gtk/gtktextview.h:73: error: Syntaxfehler before "guint"
/usr/include/gtk/gtktextview.h:85: error: Syntaxfehler before '*' token
/usr/include/gtk/gtktextview.h:86: error: Syntaxfehler before "editable"
/usr/include/gtk/gtktextview.h:119: error: `width' redeclared as different kind of symbol
/usr/include/gtk/gtklayout.h:60: error: previous declaration of `width'
/usr/include/gtk/gtktextview.h:120: error: `height' redeclared as different kind of symbol
/usr/include/gtk/gtkoptionmenu.h:61: error: previous declaration of `height'
/usr/include/gtk/gtktextview.h:138: error: Syntaxfehler before "blink_timeout"
/usr/include/gtk/gtktextview.h:140: error: Syntaxfehler before "first_validate_idle"
/usr/include/gtk/gtktextview.h:141: error: Syntaxfehler before "incremental_validate_idle"
/usr/include/gtk/gtktextview.h:149: error: Syntaxfehler before '*' token
/usr/include/gtk/gtktextview.h:154: error: Syntaxfehler before '}' token
/usr/include/gtk/gtktextview.h:158: error: field `parent_class' has incomplete type
/usr/include/gtk/gtktextview.h:188: error: Syntaxfehler before '*' token
/usr/include/gtk/gtktextview.h:216: error: Syntaxfehler before "gtk_text_view_get_type"
/usr/include/gtk/gtktextview.h:216: error: Syntaxfehler before "G_GNUC_CONST"
/usr/include/gtk/gtktextview.h:224: error: Syntaxfehler before "gdouble"
/usr/include/gtk/gtktextview.h:227: error: `gtk_text_view_scroll_to_iter' declared as function returning a function
/usr/include/gtk/gtktextview.h:230: error: Syntaxfehler before "gdouble"
/usr/include/gtk/gtktextview.h:237: error: `gtk_text_view_move_mark_onscreen' declared as function returning a function
/usr/include/gtk/gtktextview.h:238: error: `gtk_text_view_place_cursor_onscreen' declared as function returning a function
/usr/include/gtk/gtktextview.h:241: error: Syntaxfehler before "GdkRectangle"
/usr/include/gtk/gtktextview.h:244: error: `gtk_text_view_get_cursor_visible' declared as function returning a function
/usr/include/gtk/gtktextview.h:248: error: Syntaxfehler before "GdkRectangle"
/usr/include/gtk/gtktextview.h:276: error: Syntaxfehler before '*' token
/usr/include/gtk/gtktextview.h:279: error: Syntaxfehler before "GdkWindow"
/usr/include/gtk/gtktextview.h:285: error: `gtk_text_view_get_border_window_size' declared as function returning a function
/usr/include/gtk/gtktextview.h:288: error: `gtk_text_view_forward_display_line' declared as function returning a function
/usr/include/gtk/gtktextview.h:290: error: `gtk_text_view_backward_display_line' declared as function returning a function
/usr/include/gtk/gtktextview.h:292: error: `gtk_text_view_forward_display_line_end' declared as function returning a function
/usr/include/gtk/gtktextview.h:294: error: `gtk_text_view_backward_display_line_start' declared as function returning a function
/usr/include/gtk/gtktextview.h:296: error: `gtk_text_view_starts_display_line' declared as function returning a function
/usr/include/gtk/gtktextview.h:299: error: `gtk_text_view_move_visually' declared as function returning a function
/usr/include/gtk/gtktextview.h:326: error: `gtk_text_view_get_editable' declared as function returning a function
/usr/include/gtk/gtktextview.h:329: error: `gtk_text_view_get_overwrite' declared as function returning a function
/usr/include/gtk/gtktextview.h:332: error: `gtk_text_view_get_accepts_tab' declared as function returning a function
/usr/include/gtk/gtktextview.h:335: error: `gtk_text_view_get_pixels_above_lines' declared as function returning a function
/usr/include/gtk/gtktextview.h:338: error: `gtk_text_view_get_pixels_below_lines' declared as function returning a function
/usr/include/gtk/gtktextview.h:341: error: `gtk_text_view_get_pixels_inside_wrap' declared as function returning a function
/usr/include/gtk/gtktextview.h:347: error: `gtk_text_view_get_left_margin' declared as function returning a function
/usr/include/gtk/gtktextview.h:350: error: `gtk_text_view_get_right_margin' declared as function returning a function
/usr/include/gtk/gtktextview.h:353: error: `gtk_text_view_get_indent' declared as function returning a function
/usr/include/gtk/gtktextview.h:355: error: Syntaxfehler before "PangoTabArray"
/usr/include/gtk/gtktextview.h:356: error: Syntaxfehler before '*' token
In file included from /usr/include/gtk/gtk.h:152,
                 from hallo4.c:1:
/usr/include/gtk/gtktipsquery.h:61: error: field `label' has incomplete type
/usr/include/gtk/gtktipsquery.h:63: error: Syntaxfehler before "guint"
/usr/include/gtk/gtktipsquery.h:66: error: Syntaxfehler before '*' token
/usr/include/gtk/gtktipsquery.h:71: error: Syntaxfehler before '*' token
/usr/include/gtk/gtktipsquery.h:72: error: Syntaxfehler before '}' token
/usr/include/gtk/gtktipsquery.h:82: error: Syntaxfehler before '*' token
/usr/include/gtk/gtktipsquery.h:86: error: Syntaxfehler before '*' token
/usr/include/gtk/gtktipsquery.h:88: error: `widget_selected' declared as function returning a function
/usr/include/gtk/gtktipsquery.h:99: error: Syntaxfehler before "gtk_tips_query_get_type"
/usr/include/gtk/gtktipsquery.h:99: error: Syntaxfehler before "G_GNUC_CONST"
/usr/include/gtk/gtktipsquery.h:106: error: Syntaxfehler before '*' token
In Datei, eingefügt von /usr/include/gtk/gtk.h:156,
                    von hallo4.c:1:
/usr/include/gtk/gtktoolbar.h:35:21: gdk/gdk.h: Datei oder Verzeichnis nicht gefunden
In file included from /usr/include/gtk/gtk.h:156,
                 from hallo4.c:1:
/usr/include/gtk/gtktoolbar.h:60: error: Syntaxfehler before "typedef"
/usr/include/gtk/gtktoolbar.h:93: error: field `container' has incomplete type
/usr/include/gtk/gtktoolbar.h:96: error: field `num_children' declared as a function
/usr/include/gtk/gtktoolbar.h:97: error: Syntaxfehler before "GList"
/usr/include/gtk/gtktoolbar.h:99: error: conflicting types for `style'
/usr/include/gtk/gtkclist.h:424: error: previous declaration of `style'
/usr/include/gtk/gtktoolbar.h:108: error: Syntaxfehler before "style_set_connection"
/usr/include/gtk/gtktoolbar.h:109: error: Syntaxfehler before "icon_size_connection"
/usr/include/gtk/gtktoolbar.h:111: error: Syntaxfehler before "style_set"
/usr/include/gtk/gtktoolbar.h:117: error: field `parent_class' has incomplete type
/usr/include/gtk/gtktoolbar.h:127: error: `popup_context_menu' declared as function returning a function
/usr/include/gtk/gtktoolbar.h:135: error: Syntaxfehler before "gtk_toolbar_get_type"
/usr/include/gtk/gtktoolbar.h:135: error: Syntaxfehler before "G_GNUC_CONST"
/usr/include/gtk/gtktoolbar.h:141: error: `gtk_toolbar_get_item_index' declared as function returning a function
/usr/include/gtk/gtktoolbar.h:142: error: `gtk_toolbar_get_n_items' declared as function returning a function
/usr/include/gtk/gtktoolbar.h:145: error: `gtk_toolbar_get_show_arrow' declared as function returning a function
/usr/include/gtk/gtktoolbar.h:151: error: `gtk_toolbar_get_tooltips' declared as function returning a function
/usr/include/gtk/gtktoolbar.h:162: error: `gtk_toolbar_get_drop_index' declared as function returning a function
/usr/include/gtk/gtktoolbar.h:168: error: Syntaxfehler before '*' token
/usr/include/gtk/gtktoolbar.h:168: error: Syntaxfehler before '*' token
/usr/include/gtk/gtktoolbar.h:171: error: Syntaxfehler before "GdkRectangle"
/usr/include/gtk/gtktoolbar.h:173: error: `_gtk_toolbar_get_default_space_size' declared as function returning a function
/usr/include/gtk/gtktoolbar.h:190: error: Syntaxfehler before "gpointer"
/usr/include/gtk/gtktoolbar.h:197: error: Syntaxfehler before "gpointer"
/usr/include/gtk/gtktoolbar.h:204: error: Syntaxfehler before "gpointer"
/usr/include/gtk/gtktoolbar.h:209: error: Syntaxfehler before '*' token
/usr/include/gtk/gtktoolbar.h:232: error: Syntaxfehler before "gpointer"
/usr/include/gtk/gtktoolbar.h:242: error: Syntaxfehler before "gpointer"
/usr/include/gtk/gtktoolbar.h:252: error: Syntaxfehler before "gpointer"
In file included from /usr/include/gtk/gtk.h:162,
                 from hallo4.c:1:
/usr/include/gtk/gtktreednd.h:35: error: Syntaxfehler before "typedef"
/usr/include/gtk/gtktreednd.h:40: error: Syntaxfehler before "GTypeInterface"
/usr/include/gtk/gtktreednd.h:45: error: `row_draggable' declared as function returning a function
/usr/include/gtk/gtktreednd.h:49: error: `drag_data_get' declared as function returning a function
/usr/include/gtk/gtktreednd.h:49: error: conflicting types for `drag_data_get'
/usr/include/gtk/gtkwidget.h:363: error: previous declaration of `drag_data_get'/usr/include/gtk/gtktreednd.h:52: error: `drag_data_delete' declared as function returning a function
/usr/include/gtk/gtktreednd.h:52: error: conflicting types for `drag_data_delete'
/usr/include/gtk/gtkwidget.h:365: error: previous declaration of `drag_data_delete'
/usr/include/gtk/gtktreednd.h:53: error: Syntaxfehler before '}' token
/usr/include/gtk/gtktreednd.h:55: error: Syntaxfehler before "gtk_tree_drag_source_get_type"
/usr/include/gtk/gtktreednd.h:55: error: Syntaxfehler before "G_GNUC_CONST"
/usr/include/gtk/gtktreednd.h:59: error: `gtk_tree_drag_source_row_draggable' declared as function returning a function
/usr/include/gtk/gtktreednd.h:63: error: `gtk_tree_drag_source_drag_data_delete' declared as function returning a function
/usr/include/gtk/gtktreednd.h:70: error: `gtk_tree_drag_source_drag_data_get' declared as function returning a function
/usr/include/gtk/gtktreednd.h:82: error: Syntaxfehler before "GTypeInterface"
/usr/include/gtk/gtktreednd.h:88: error: `drag_data_received' declared as function returning a function
/usr/include/gtk/gtktreednd.h:88: error: conflicting types for `drag_data_received'
/usr/include/gtk/gtkwidget.h:387: error: previous declaration of `drag_data_received'
/usr/include/gtk/gtktreednd.h:92: error: `row_drop_possible' declared as function returning a function
/usr/include/gtk/gtktreednd.h:93: error: Syntaxfehler before '}' token
/usr/include/gtk/gtktreednd.h:95: error: Syntaxfehler before "gtk_tree_drag_dest_get_type"
/usr/include/gtk/gtktreednd.h:95: error: Syntaxfehler before "G_GNUC_CONST"
/usr/include/gtk/gtktreednd.h:102: error: `gtk_tree_drag_dest_drag_data_received' declared as function returning a function
/usr/include/gtk/gtktreednd.h:108: error: `gtk_tree_drag_dest_row_drop_possible' declared as function returning a function
/usr/include/gtk/gtktreednd.h:116: error: `gtk_tree_set_row_drag_data' declared as function returning a function
/usr/include/gtk/gtktreednd.h:119: error: `gtk_tree_get_row_drag_data' declared as function returning a function
In file included from /usr/include/gtk/gtk.h:166,
                 from hallo4.c:1:
/usr/include/gtk/gtktreemodelsort.h:35: error: Syntaxfehler before "typedef"
/usr/include/gtk/gtktreemodelsort.h:40: error: Syntaxfehler before "GObject"
/usr/include/gtk/gtktreemodelsort.h:45: error: Syntaxfehler before "child_flags"/usr/include/gtk/gtktreemodelsort.h:50: error: Syntaxfehler before '*' token
/usr/include/gtk/gtktreemodelsort.h:55: error: Syntaxfehler before "default_sort_func"
/usr/include/gtk/gtktreemodelsort.h:56: error: Syntaxfehler before "default_sort_data"
/usr/include/gtk/gtktreemodelsort.h:60: error: Syntaxfehler before "changed_id"
/usr/include/gtk/gtktreemodelsort.h:61: error: Syntaxfehler before "inserted_id"/usr/include/gtk/gtktreemodelsort.h:62: error: Syntaxfehler before "has_child_toggled_id"
/usr/include/gtk/gtktreemodelsort.h:63: error: Syntaxfehler before "deleted_id"
/usr/include/gtk/gtktreemodelsort.h:64: error: Syntaxfehler before "reordered_id"
/usr/include/gtk/gtktreemodelsort.h:69: error: Syntaxfehler before "GObjectClass"
/usr/include/gtk/gtktreemodelsort.h:76: error: Syntaxfehler before '}' token
/usr/include/gtk/gtktreemodelsort.h:79: error: Syntaxfehler before "gtk_tree_model_sort_get_type"
/usr/include/gtk/gtktreemodelsort.h:79: error: Syntaxfehler before "G_GNUC_CONST"
/usr/include/gtk/gtktreemodelsort.h:96: error: `gtk_tree_model_sort_iter_is_valid' declared as function returning a function
In Datei, eingefügt von /usr/include/gtk/gtk.h:167,
                    von hallo4.c:1:
/usr/include/gtk/gtktreeselection.h:23:25: glib-object.h: Datei oder Verzeichnis nicht gefunden
In file included from /usr/include/gtk/gtk.h:167,
                 from hallo4.c:1:
/usr/include/gtk/gtktreeselection.h:37: error: Syntaxfehler before "typedef"
/usr/include/gtk/gtktreeselection.h:41: error: Syntaxfehler before "gpointer"
/usr/include/gtk/gtktreeselection.h:41: error: `GtkTreeSelectionFunc' declared as function returning a function
/usr/include/gtk/gtktreeselection.h:45: error: Syntaxfehler before "gpointer"
/usr/include/gtk/gtktreeselection.h:49: error: Syntaxfehler before "GObject"
/usr/include/gtk/gtktreeselection.h:54: error: conflicting types for `type'
/usr/include/gtk/gtkselection.h:59: error: previous declaration of `type'
/usr/include/gtk/gtktreeselection.h:56: error: Syntaxfehler before "user_data"
/usr/include/gtk/gtktreeselection.h:58: error: Syntaxfehler before '}' token
/usr/include/gtk/gtktreeselection.h:62: error: Syntaxfehler before "GObjectClass"
/usr/include/gtk/gtktreeselection.h:64: error: conflicting types for `changed'
/usr/include/gtk/gtktextbuffer.h:101: error: previous declaration of `changed'
/usr/include/gtk/gtktreeselection.h:71: error: Syntaxfehler before '}' token
/usr/include/gtk/gtktreeselection.h:74: error: Syntaxfehler before "gtk_tree_selection_get_type"
/usr/include/gtk/gtktreeselection.h:81: error: Syntaxfehler before "gpointer"
/usr/include/gtk/gtktreeselection.h:83: error: Syntaxfehler before "gtk_tree_selection_get_user_data"
/usr/include/gtk/gtktreeselection.h:90: error: `gtk_tree_selection_get_selected' declared as function returning a function
/usr/include/gtk/gtktreeselection.h:91: error: Syntaxfehler before '*' token
/usr/include/gtk/gtktreeselection.h:93: error: `gtk_tree_selection_count_selected_rows' declared as function returning a function
/usr/include/gtk/gtktreeselection.h:96: error: Syntaxfehler before "gpointer"
/usr/include/gtk/gtktreeselection.h:106: error: `gtk_tree_selection_path_is_selected' declared as function returning a function
/usr/include/gtk/gtktreeselection.h:108: error: `gtk_tree_selection_iter_is_selected' declared as function returning a function
In file included from /usr/include/gtk/gtk.h:168,
                 from hallo4.c:1:
/usr/include/gtk/gtktreestore.h:43: error: Syntaxfehler before "GObject"
/usr/include/gtk/gtktreestore.h:46: error: Syntaxfehler before "root"
/usr/include/gtk/gtktreestore.h:47: error: Syntaxfehler before "last"
/usr/include/gtk/gtktreestore.h:47: error: `last' redeclared as different kind of symbol
/usr/include/gtk/gtkcurve.h:74: error: previous declaration of `last'
/usr/include/gtk/gtktreestore.h:50: error: Syntaxfehler before '*' token
/usr/include/gtk/gtktreestore.h:52: error: Syntaxfehler before '*' token
/usr/include/gtk/gtktreestore.h:53: error: Syntaxfehler before "default_sort_func"
/usr/include/gtk/gtktreestore.h:54: error: Syntaxfehler before "default_sort_data"
/usr/include/gtk/gtktreestore.h:56: error: Syntaxfehler before "columns_dirty"
/usr/include/gtk/gtktreestore.h:61: error: Syntaxfehler before "GObjectClass"
/usr/include/gtk/gtktreestore.h:68: error: Syntaxfehler before '}' token
/usr/include/gtk/gtktreestore.h:71: error: Syntaxfehler before "gtk_tree_store_get_type"
/usr/include/gtk/gtktreestore.h:75: error: Syntaxfehler before "GType"
/usr/include/gtk/gtktreestore.h:78: error: Syntaxfehler before "GType"
/usr/include/gtk/gtktreestore.h:85: error: Syntaxfehler before "GValue"
/usr/include/gtk/gtktreestore.h:93: error: `gtk_tree_store_remove' declared as function returning a function
/usr/include/gtk/gtktreestore.h:114: error: `gtk_tree_store_is_ancestor' declared as function returning a function
/usr/include/gtk/gtktreestore.h:116: error: `gtk_tree_store_iter_depth' declared as function returning a function
/usr/include/gtk/gtktreestore.h:119: error: `gtk_tree_store_iter_is_valid' declared as function returning a function
In Datei, eingefügt von /usr/include/gtk/gtk.h:172,
                    von hallo4.c:1:
/usr/include/gtk/gtkuimanager.h:34:18: glib.h: Datei oder Verzeichnis nicht gefunden
/usr/include/gtk/gtkuimanager.h:35:25: glib-object.h: Datei oder Verzeichnis nicht gefunden
In file included from /usr/include/gtk/gtk.h:172,
                 from hallo4.c:1:
/usr/include/gtk/gtkuimanager.h:50: error: Syntaxfehler before "typedef"
/usr/include/gtk/gtkuimanager.h:56: error: Syntaxfehler before "GObject"
/usr/include/gtk/gtkuimanager.h:60: error: conflicting types for `private_data'
/usr/include/gtk/gtkcalendar.h:92: error: previous declaration of `private_data'/usr/include/gtk/gtkuimanager.h:61: error: Syntaxfehler before '}' token
/usr/include/gtk/gtkuimanager.h:64: error: Syntaxfehler before "GObjectClass"
/usr/include/gtk/gtkuimanager.h:72: error: conflicting types for `connect_proxy'/usr/include/gtk/gtkaction.h:72: error: previous declaration of `connect_proxy'
/usr/include/gtk/gtkuimanager.h:75: error: conflicting types for `disconnect_proxy'
/usr/include/gtk/gtkaction.h:74: error: previous declaration of `disconnect_proxy'
/usr/include/gtk/gtkuimanager.h:86: error: Syntaxfehler before '}' token
/usr/include/gtk/gtkuimanager.h:101: error: Syntaxfehler before "gtk_ui_manager_get_type"
/usr/include/gtk/gtkuimanager.h:105: error: `gtk_ui_manager_get_add_tearoffs' declared as function returning a function
/usr/include/gtk/gtkuimanager.h:111: error: Syntaxfehler before '*' token
/usr/include/gtk/gtkuimanager.h:114: error: Syntaxfehler before '*' token
/usr/include/gtk/gtkuimanager.h:115: error: Syntaxfehler before '*' token
/usr/include/gtk/gtkuimanager.h:118: error: Syntaxfehler before '*' token
/usr/include/gtk/gtkuimanager.h:119: error: Syntaxfehler before "gtk_ui_manager_add_ui_from_string"
/usr/include/gtk/gtkuimanager.h:120: error: Syntaxfehler before '*' token
/usr/include/gtk/gtkuimanager.h:123: error: Syntaxfehler before "gtk_ui_manager_add_ui_from_file"
/usr/include/gtk/gtkuimanager.h:124: error: Syntaxfehler before '*' token
/usr/include/gtk/gtkuimanager.h:127: error: Syntaxfehler before "guint"
/usr/include/gtk/gtkuimanager.h:134: error: Syntaxfehler before "guint"
/usr/include/gtk/gtkuimanager.h:135: error: Syntaxfehler before '*' token
/usr/include/gtk/gtkuimanager.h:137: error: Syntaxfehler before "gtk_ui_manager_new_merge_id"
In file included from /usr/include/gtk/gtk.h:173,
                 from hallo4.c:1:
/usr/include/gtk/gtkvbbox.h:47: error: Syntaxfehler before "typedef"
/usr/include/gtk/gtkvbbox.h:52: error: field `button_box' has incomplete type
/usr/include/gtk/gtkvbbox.h:61: error: Syntaxfehler before "gtk_vbutton_box_get_type"
/usr/include/gtk/gtkvbbox.h:61: error: Syntaxfehler before "G_GNUC_CONST"
/usr/include/gtk/gtkvbbox.h:67: error: `gtk_vbutton_box_get_spacing_default' declared as function returning a function
In file included from /usr/include/gtk/gtk.h:177,
                 from hallo4.c:1:
/usr/include/gtk/gtkvpaned.h:50: error: field `paned' has incomplete type
/usr/include/gtk/gtkvpaned.h:58: error: Syntaxfehler before "gtk_vpaned_get_type"
/usr/include/gtk/gtkvpaned.h:58: error: Syntaxfehler before "G_GNUC_CONST"
In Datei, eingefügt von /usr/include/gtk/gtk.h:178,
                    von hallo4.c:1:
/usr/include/gtk/gtkvruler.h:41:21: gdk/gdk.h: Datei oder Verzeichnis nicht gefunden
In file included from /usr/include/gtk/gtk.h:178,
                 from hallo4.c:1:
/usr/include/gtk/gtkvruler.h:63: error: field `ruler' has incomplete type
/usr/include/gtk/gtkvruler.h:72: error: Syntaxfehler before "gtk_vruler_get_type"
/usr/include/gtk/gtkvruler.h:72: error: Syntaxfehler before "G_GNUC_CONST"
In Datei, eingefügt von /usr/include/gtk/gtk.h:179,
                    von hallo4.c:1:
/usr/include/gtk/gtkvscale.h:31:21: gdk/gdk.h: Datei oder Verzeichnis nicht gefunden
In file included from /usr/include/gtk/gtk.h:179,
                 from hallo4.c:1:
/usr/include/gtk/gtkvscale.h:53: error: field `scale' has incomplete type
/usr/include/gtk/gtkvscale.h:58: error: field `parent_class' has incomplete type/usr/include/gtk/gtkvscale.h:62: error: Syntaxfehler before "gtk_vscale_get_type"
/usr/include/gtk/gtkvscale.h:62: error: Syntaxfehler before "G_GNUC_CONST"
/usr/include/gtk/gtkvscale.h:64: error: Syntaxfehler before "min"
In Datei, eingefügt von /usr/include/gtk/gtk.h:181,
                    von hallo4.c:1:
/usr/include/gtk/gtkvseparator.h:31:21: gdk/gdk.h: Datei oder Verzeichnis nicht gefunden
In file included from /usr/include/gtk/gtk.h:181,
                 from hallo4.c:1:
/usr/include/gtk/gtkvseparator.h:62: error: Syntaxfehler before "gtk_vseparator_get_type"
/usr/include/gtk/gtkvseparator.h:62: error: Syntaxfehler before "G_GNUC_CONST"
hallo4.c: In Funktion »main«:
hallo4.c:9: error: storage size of `p_MainWindow' isn't known
hallo4.c:10: Warnung: Verarbeiten des Argumentes 2 von »gtk_init« von inkompatiblem Zeigertyp
hallo4.c:13: Warnung: implicit declaration of function `G_TYPE_CHECK_INSTANCE_CAST'
hallo4.c:13: error: `hauptfenster' undeclared (first use in this function)
hallo4.c:13: error: (Each undeclared identifier is reported only once
hallo4.c:13: error: for each function it appears in.)
hallo4.c:13: Warnung: implicit declaration of function `gtk_object_get_type'
hallo4.c:13: error: Syntaxfehler before "GtkObject"
hallo4.c:13: error: `NULL' undeclared (first use in this function)
hallo4.c:13: Warnung: left-hand operand of comma expression has no effect
hallo4.c:13: Warnung: left-hand operand of comma expression has no effect
hallo4.c:13: Warnung: left-hand operand of comma expression has no effect
hallo4.c:13: Warnung: left-hand operand of comma expression has no effect
hallo4.c:13: Warnung: left-hand operand of comma expression has no effect
hallo4.c:13: Warnung: left-hand operand of comma expression has no effect
hallo4.c:13: error: Syntaxfehler before ')' token
hallo4.c:9: Warnung: unused variable `p_MainWindow'
hallo4.c:21:2: Warnung: Kein Newline am Dateiende
hallo4.c: Auf höchster Ebene:
/usr/include/gtk/gtksizegroup.h:52: error: storage size of `requisition' isn't known
/usr/include/gtk/gtkruler.h:107: error: storage size of `subdivide' isn't known
/usr/include/gtk/gtktexttag.h:165: error: storage size of `appearance' isn't known




  1. Antwort von youssef 0
    Re: Gtk+ Header mit Parse Fehlern unter C mit gcc
    hallo Alexander ?
    wie hast du dein programm compiliert ?
    ich habe zwar noch nie mit gtk+ gearbeitet aber es sieht aus als der Linker die Bibliotheken nicht findet.

    youssef
    1 Kommentare
    • von Alexander 0
      Danke
      als der Linker die Bibliotheken nicht findet.
      Und genau das wars dann auch!

      Danke.