Re gtk/gtk.h Error
- From: "Udaya Kumar" <urspcbs gmail com>
- To: gtk-devel-list gnome org
- Subject: Re gtk/gtk.h Error
- Date: Fri, 19 Jan 2007 15:45:59 +0530
Dear Sir /Madam
I am newbie to Linux Programming
I have Redhat EL4 on my PC.
I have installed the following.
gtk2-2.4.13-12
glib-1.2.10-15
But still when I Compile the Program, I get the follwoing error.
[root localhost ~]# gcc -Wall -g window.c -o window `gtk-config --cflags` `gtk-config --libs`
bash: gtk-config: command not found
bash: gtk-config: command not found
window.c:5:21: gtk/gtk.h: No such file or directory
window.c:6:18: glib.h: No such file or directory
window.c: In function `main':
window.c:11: error: `GtkWidget' undeclared (first use in this function)
window.c:11: error: (Each undeclared identifier is reported only once
window.c:11: error: for each function it appears in.)
window.c:11: error: `window' undeclared (first use in this function)
window.c:14: warning: implicit declaration of function `gtk_init'
window.c:17: warning: implicit declaration of function `gtk_window_new'
window.c:17: error: `GTK_WINDOW_TOPLEVEL' undeclared (first use in this function)
window.c:20: warning: implicit declaration of function `gtk_widget_show'
window.c:23: warning: implicit declaration of function `gtk_main'
With this message I have included the source of window.c
Awaiting for your reply
Regards
Udaya,
India.
/*
*File name: window.c
*/
#include <gtk/gtk.h>
#include <glib.h>
int main (int argc, char *argv[])
{
/*-- Declare the GTK Widgets used in the program --*/
GtkWidget *window;
/*-- Initialize GTK --*/
gtk_init (&argc, &argv);
/*-- Create the new window --*/
window = gtk_window_new(GTK_WINDOW_TOPLEVEL);
/*-- Display the window --*/
gtk_widget_show(window);
/*-- Start the GTK event loop --*/
gtk_main();
/*-- Return 0 if exit is successful --*/
return 0;
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]