Hi there,
Glade as generated my main.c and here is what it gives me:
Code:
/*
* Initial main.c file generated by Glade. Edit as required.
* Glade will not overwrite this file.
*/
#ifdef HAVE_CONFIG_H
# include <config.h>
#endif
#include <gtk/gtk.h>
#include "interface.h"
#include "support.h"
#ifdef G_OS_WIN32
char *package_prefix;
char *package_datadir;
#endif
int
main (int argc, char *argv[])
{
GtkWidget *mediacenter;
#ifdef G_OS_WIN32
gchar *temp;
package_prefix = g_win32_get_package_installation_directory (NULL, NULL);
package_datadir = g_strdup_printf ("%s%s", package_prefix, "/share");
#endif
#ifdef ENABLE_NLS
#ifdef G_OS_WIN32
temp = g_strdup_printf ("%s%s", package_prefix, "/lib/locale");
bindtextdomain (GETTEXT_PACKAGE, temp);
g_free (temp);
#else
bindtextdomain (GETTEXT_PACKAGE, PACKAGE_LOCALE_DIR);
#endif
bind_textdomain_codeset (GETTEXT_PACKAGE, "UTF-8");
textdomain (GETTEXT_PACKAGE);
#endif
gtk_set_locale ();
gtk_init (&argc, &argv);
#ifdef G_OS_WIN32
temp = g_strdup_printf ("%s/%s%s", package_datadir, PACKAGE, "/pixmaps");
add_pixmap_directory (temp);
g_free (temp);
#else
add_pixmap_directory (PACKAGE_DATA_DIR "/" PACKAGE "/pixmaps");
#endif
/*
* The following code was added by Glade to create one of each component
* (except popup menus), just so that you see something after building
* the project. Delete any components that you don't want shown initially.
*/
mediacenter = create_mediacenter ();
gtk_widget_show (mediacenter);
gtk_main ();
#ifdef G_OS_WIN32
g_free (package_prefix);
g_free (package_datadir);
#endif
return 0;
}
But it gives me an error because of this line:
Code:
#ifdef G_OS_WIN32
temp = g_strdup_printf ("%s/%s%s", package_datadir, PACKAGE, "/pixmaps");
add_pixmap_directory (temp);
g_free (temp);
#else
add_pixmap_directory (PACKAGE_DATA_DIR "/" PACKAGE "/pixmaps");
#endif
And finally the error is:
Code:
Compiling...
interface.c
main.c
c:\projects\elmonia\media center\src\main.c(48) : error C2065: 'PACKAGE' : undeclared identifier
support.c
Error executing cl.exe.
main.exe - 1 error(s), 0 warning(s)
Why is it giving me that error??