[Anjuta-list] help



Hello again everyone. 

Thank to all for your comments, but I still have the
same problem, I am using ubuntu 7.10 and anjuta 2.2.0,
and try to create a new project of gtk + with autogen:
the code is the next:



#include <sys/types.h>

#include <sys/stat.h>

#include <unistd.h>

#include <string.h>

#include <stdio.h>







#include <gtk/gtk.h>

#include <glade/glade.h>







/*

 * Standard gettext macros.

 */

#ifdef ENABLE_NLS

#  include <libintl.h>

#  undef _

#  define _(String) dgettext (PACKAGE, String)

#  ifdef gettext_noop

#    define N_(String) gettext_noop (String)

#  else

#    define N_(String) (String)

#  endif

#else

#  define textdomain(String) (String)

#  define gettext(String) (String)

#  define dgettext(Domain,Message) (Message)

#  define dcgettext(Domain,Message,Type) (Message)

#  define bindtextdomain(Domain,Directory) (Domain)

#  define _(String) (String)

#  define N_(String) (String)

#endif







#include "callbacks.h"



/* For testing propose use the local (not installed)
glade file */

/* #define GLADE_FILE
PACKAGE_DATA_DIR"/gtk-foobar/glade/gtk-foobar.glade"
*/

#define GLADE_FILE "gtk-foobar.glade"

	

GtkWidget*

create_window (void)

{

	GtkWidget *window;

	GladeXML *gxml;

	

	gxml = glade_xml_new (GLADE_FILE, NULL, NULL);

	

	/* This is important */

	glade_xml_signal_autoconnect (gxml);

	window = glade_xml_get_widget (gxml, "window");

	

	return window;

}





int

main (int argc, char *argv[])

{

 	GtkWidget *window;





#ifdef ENABLE_NLS

	bindtextdomain (GETTEXT_PACKAGE, PACKAGE_LOCALE_DIR);

	bind_textdomain_codeset (GETTEXT_PACKAGE, "UTF-8");

	textdomain (GETTEXT_PACKAGE);

#endif



	

	gtk_set_locale ();

	gtk_init (&argc, &argv);



	window = create_window ();

	gtk_widget_show (window);



	gtk_main ();

	return 0;

}


But when I try to compile the project, anjuta get me
the same error that I mentioned before:

make main.o

cc    -c -o main.o main.c

main.c:10:21: error: gtk/gtk.h: No such file or
directory

main.c:11:25: error: glade/glade.h: No such file or
directory

main.c:45: error: expected ?=?, ?,?, ?;?, ?asm? or
?__attribute__? before ?*? token

main.c: In function ?main?:

main.c:64: error: ?GtkWidget? undeclared (first use in
this function)

main.c:64: error: (Each undeclared identifier is
reported only once

main.c:64: error: for each function it appears in.)

main.c:64: error: ?window? undeclared (first use in
this function)

make: *** [main.o] Error 1

Completed... unsuccessful

Total time taken: 1 secs

that anjuta did not find gtk.h, I try to find some
options that indicate where I tell anjuta where to
look gtk.h, but I did not find any option.

help me.





      ____________________________________________________________________________________
¡Capacidad ilimitada de almacenamiento en tu correo!
No te preocupes más por el espacio de tu cuenta con Correo Yahoo!:                      
http://correo.yahoo.com.mx/




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