forked from AuroraMiddleware/gtk
gdk-pixbuf/Makefile.am (uninstall-libtool-import-lib) Fix typo, thanks to
2002-04-18 Tor Lillqvist <tml@iki.fi> * gdk-pixbuf/Makefile.am (uninstall-libtool-import-lib) * gdk/Makefile.am (uninstall-libtool-import-lib): Fix typo, thanks to David Sterba for noticing. * gtk/gtkmain.h * gtk/gtkmain.c (gtk_init_abi_check, gtk_init_check_abi_check): In GTK+ 2.0 the GtkWindow struct actually is the same size in gcc on Win32 whether compiled with -fnative-struct or not. Unfortunately this wan't noticed until now. So, from now on, check some other struct, too, for which the use of -fnative-struct still matters. GtkBox is one such.
This commit is contained in:
parent
a3045c84ef
commit
40d637ec03
14
ChangeLog
14
ChangeLog
@ -1,3 +1,17 @@
|
||||
2002-04-18 Tor Lillqvist <tml@iki.fi>
|
||||
|
||||
* gdk-pixbuf/Makefile.am (uninstall-libtool-import-lib)
|
||||
* gdk/Makefile.am (uninstall-libtool-import-lib): Fix typo,
|
||||
thanks to David Sterba for noticing.
|
||||
|
||||
* gtk/gtkmain.h
|
||||
* gtk/gtkmain.c (gtk_init_abi_check, gtk_init_check_abi_check): In
|
||||
GTK+ 2.0 the GtkWindow struct actually is the same size in gcc on
|
||||
Win32 whether compiled with -fnative-struct or not. Unfortunately
|
||||
this wan't noticed until now. So, from now on, check some other
|
||||
struct, too, for which the use of -fnative-struct still
|
||||
matters. GtkBox is one such.
|
||||
|
||||
Thu Apr 18 00:23:31 2002 Kristian Rietveld <kris@gtk.org>
|
||||
|
||||
* gtk/gtktreemodelsort.c
|
||||
|
@ -1,3 +1,17 @@
|
||||
2002-04-18 Tor Lillqvist <tml@iki.fi>
|
||||
|
||||
* gdk-pixbuf/Makefile.am (uninstall-libtool-import-lib)
|
||||
* gdk/Makefile.am (uninstall-libtool-import-lib): Fix typo,
|
||||
thanks to David Sterba for noticing.
|
||||
|
||||
* gtk/gtkmain.h
|
||||
* gtk/gtkmain.c (gtk_init_abi_check, gtk_init_check_abi_check): In
|
||||
GTK+ 2.0 the GtkWindow struct actually is the same size in gcc on
|
||||
Win32 whether compiled with -fnative-struct or not. Unfortunately
|
||||
this wan't noticed until now. So, from now on, check some other
|
||||
struct, too, for which the use of -fnative-struct still
|
||||
matters. GtkBox is one such.
|
||||
|
||||
Thu Apr 18 00:23:31 2002 Kristian Rietveld <kris@gtk.org>
|
||||
|
||||
* gtk/gtktreemodelsort.c
|
||||
|
@ -1,3 +1,17 @@
|
||||
2002-04-18 Tor Lillqvist <tml@iki.fi>
|
||||
|
||||
* gdk-pixbuf/Makefile.am (uninstall-libtool-import-lib)
|
||||
* gdk/Makefile.am (uninstall-libtool-import-lib): Fix typo,
|
||||
thanks to David Sterba for noticing.
|
||||
|
||||
* gtk/gtkmain.h
|
||||
* gtk/gtkmain.c (gtk_init_abi_check, gtk_init_check_abi_check): In
|
||||
GTK+ 2.0 the GtkWindow struct actually is the same size in gcc on
|
||||
Win32 whether compiled with -fnative-struct or not. Unfortunately
|
||||
this wan't noticed until now. So, from now on, check some other
|
||||
struct, too, for which the use of -fnative-struct still
|
||||
matters. GtkBox is one such.
|
||||
|
||||
Thu Apr 18 00:23:31 2002 Kristian Rietveld <kris@gtk.org>
|
||||
|
||||
* gtk/gtktreemodelsort.c
|
||||
|
@ -1,3 +1,17 @@
|
||||
2002-04-18 Tor Lillqvist <tml@iki.fi>
|
||||
|
||||
* gdk-pixbuf/Makefile.am (uninstall-libtool-import-lib)
|
||||
* gdk/Makefile.am (uninstall-libtool-import-lib): Fix typo,
|
||||
thanks to David Sterba for noticing.
|
||||
|
||||
* gtk/gtkmain.h
|
||||
* gtk/gtkmain.c (gtk_init_abi_check, gtk_init_check_abi_check): In
|
||||
GTK+ 2.0 the GtkWindow struct actually is the same size in gcc on
|
||||
Win32 whether compiled with -fnative-struct or not. Unfortunately
|
||||
this wan't noticed until now. So, from now on, check some other
|
||||
struct, too, for which the use of -fnative-struct still
|
||||
matters. GtkBox is one such.
|
||||
|
||||
Thu Apr 18 00:23:31 2002 Kristian Rietveld <kris@gtk.org>
|
||||
|
||||
* gtk/gtktreemodelsort.c
|
||||
|
@ -1,3 +1,17 @@
|
||||
2002-04-18 Tor Lillqvist <tml@iki.fi>
|
||||
|
||||
* gdk-pixbuf/Makefile.am (uninstall-libtool-import-lib)
|
||||
* gdk/Makefile.am (uninstall-libtool-import-lib): Fix typo,
|
||||
thanks to David Sterba for noticing.
|
||||
|
||||
* gtk/gtkmain.h
|
||||
* gtk/gtkmain.c (gtk_init_abi_check, gtk_init_check_abi_check): In
|
||||
GTK+ 2.0 the GtkWindow struct actually is the same size in gcc on
|
||||
Win32 whether compiled with -fnative-struct or not. Unfortunately
|
||||
this wan't noticed until now. So, from now on, check some other
|
||||
struct, too, for which the use of -fnative-struct still
|
||||
matters. GtkBox is one such.
|
||||
|
||||
Thu Apr 18 00:23:31 2002 Kristian Rietveld <kris@gtk.org>
|
||||
|
||||
* gtk/gtktreemodelsort.c
|
||||
|
@ -1,3 +1,17 @@
|
||||
2002-04-18 Tor Lillqvist <tml@iki.fi>
|
||||
|
||||
* gdk-pixbuf/Makefile.am (uninstall-libtool-import-lib)
|
||||
* gdk/Makefile.am (uninstall-libtool-import-lib): Fix typo,
|
||||
thanks to David Sterba for noticing.
|
||||
|
||||
* gtk/gtkmain.h
|
||||
* gtk/gtkmain.c (gtk_init_abi_check, gtk_init_check_abi_check): In
|
||||
GTK+ 2.0 the GtkWindow struct actually is the same size in gcc on
|
||||
Win32 whether compiled with -fnative-struct or not. Unfortunately
|
||||
this wan't noticed until now. So, from now on, check some other
|
||||
struct, too, for which the use of -fnative-struct still
|
||||
matters. GtkBox is one such.
|
||||
|
||||
Thu Apr 18 00:23:31 2002 Kristian Rietveld <kris@gtk.org>
|
||||
|
||||
* gtk/gtktreemodelsort.c
|
||||
|
@ -17,7 +17,7 @@ gdk_pixbuf-win32res.lo : gdk_pixbuf.rc
|
||||
install-libtool-import-lib:
|
||||
$(INSTALL) .libs/libgdk_pixbuf-$(GTK_API_VERSION).dll.a $(DESTDIR)$(libdir)
|
||||
uninstall-libtool-import-lib:
|
||||
-rm $(DESTDIR)$(libdir)/libdk_pixbuf-$(GTK_API_VERSION).dll.a
|
||||
-rm $(DESTDIR)$(libdir)/libgdk_pixbuf-$(GTK_API_VERSION).dll.a
|
||||
else
|
||||
install-libtool-import-lib:
|
||||
uninstall-libtool-import-lib:
|
||||
|
@ -42,7 +42,7 @@ gdk_win32_symbols = -export-symbols gdk.def
|
||||
install-libtool-import-lib:
|
||||
$(INSTALL) .libs/libgdk-win32-$(GTK_API_VERSION).dll.a $(DESTDIR)$(libdir)
|
||||
uninstall-libtool-import-lib:
|
||||
-rm $(DESTDIR)$(libdir)/libdk-win32-$(GTK_API_VERSION).dll.a
|
||||
-rm $(DESTDIR)$(libdir)/libgdk-win32-$(GTK_API_VERSION).dll.a
|
||||
else
|
||||
install-libtool-import-lib:
|
||||
uninstall-libtool-import-lib:
|
||||
|
@ -49,6 +49,7 @@
|
||||
#include <pango/pango-utils.h> /* For pango_split_file_list */
|
||||
|
||||
#include "gtkaccelmap.h"
|
||||
#include "gtkbox.h"
|
||||
#include "gtkdnd.h"
|
||||
#include "gtkversion.h"
|
||||
#include "gtkmain.h"
|
||||
@ -183,8 +184,6 @@ gtk_check_version (guint required_major,
|
||||
return NULL;
|
||||
}
|
||||
|
||||
#undef gtk_init_check
|
||||
|
||||
/* This checks to see if the process is running suid or sgid
|
||||
* at the current time. If so, we don't allow GTK+ to be initialized.
|
||||
* This is meant to be a mild check - we only error out if we
|
||||
@ -551,6 +550,8 @@ gtk_disable_setlocale (void)
|
||||
do_setlocale = FALSE;
|
||||
}
|
||||
|
||||
#undef gtk_init_check
|
||||
|
||||
gboolean
|
||||
gtk_init_check (int *argc,
|
||||
char ***argv)
|
||||
@ -790,23 +791,46 @@ check_sizeof_GtkWindow (size_t sizeof_GtkWindow)
|
||||
"The code using GTK+ thinks GtkWindow is of different\n"
|
||||
"size than it actually is in this build of GTK+.\n"
|
||||
"On Windows, this probably means that you have compiled\n"
|
||||
"your code with gcc without the -fnative-struct switch.");
|
||||
"your code with gcc without the -fnative-struct switch,\n"
|
||||
"or that you are using an unsupported compiler.");
|
||||
}
|
||||
|
||||
/* In GTK+ 2.0 the GtkWindow struct actually is the same size in
|
||||
* gcc-compiled code on Win32 whether compiled with -fnative-struct or
|
||||
* not. Unfortunately this wan't noticed until after GTK+ 2.0.1. So,
|
||||
* from GTK+ 2.0.2 on, check some other struct, too, where the use of
|
||||
* -fnative-struct still matters. GtkBox is one such.
|
||||
*/
|
||||
static void
|
||||
check_sizeof_GtkBox (size_t sizeof_GtkBox)
|
||||
{
|
||||
if (sizeof_GtkBox != sizeof (GtkBox))
|
||||
g_error ("Incompatible build!\n"
|
||||
"The code using GTK+ thinks GtkBox is of different\n"
|
||||
"size than it actually is in this build of GTK+.\n"
|
||||
"On Windows, this probably means that you have compiled\n"
|
||||
"your code with gcc without the -fnative-struct switch,\n"
|
||||
"or that you are using an unsupported compiler.");
|
||||
}
|
||||
|
||||
/* These two functions might get more checks added later, thus pass
|
||||
* in the number of extra args.
|
||||
*/
|
||||
void
|
||||
gtk_init_abi_check (int *argc, char ***argv, int num_checks, size_t sizeof_GtkWindow)
|
||||
gtk_init_abi_check (int *argc, char ***argv, int num_checks, size_t sizeof_GtkWindow, size_t sizeof_GtkBox)
|
||||
{
|
||||
check_sizeof_GtkWindow (sizeof_GtkWindow);
|
||||
if (num_checks >= 2)
|
||||
check_sizeof_GtkBox (sizeof_GtkBox);
|
||||
gtk_init (argc, argv);
|
||||
}
|
||||
|
||||
gboolean
|
||||
gtk_init_check_abi_check (int *argc, char ***argv, int num_checks, size_t sizeof_GtkWindow)
|
||||
gtk_init_check_abi_check (int *argc, char ***argv, int num_checks, size_t sizeof_GtkWindow, size_t sizeof_GtkBox)
|
||||
{
|
||||
check_sizeof_GtkWindow (sizeof_GtkWindow);
|
||||
if (num_checks >= 2)
|
||||
check_sizeof_GtkBox (sizeof_GtkBox);
|
||||
return gtk_init_check (argc, argv);
|
||||
}
|
||||
|
||||
|
@ -98,14 +98,16 @@ gboolean gtk_init_check (int *argc,
|
||||
void gtk_init_abi_check (int *argc,
|
||||
char ***argv,
|
||||
int num_checks,
|
||||
size_t sizeof_GtkWindow);
|
||||
size_t sizeof_GtkWindow,
|
||||
size_t sizeof_GtkBox);
|
||||
gboolean gtk_init_check_abi_check (int *argc,
|
||||
char ***argv,
|
||||
int num_checks,
|
||||
size_t sizeof_GtkWindow);
|
||||
size_t sizeof_GtkWindow,
|
||||
size_t sizeof_GtkBox);
|
||||
|
||||
#define gtk_init(argc, argv) gtk_init_abi_check (argc, argv, 1, sizeof (GtkWindow))
|
||||
#define gtk_init_check(argc, argv) gtk_init_check_abi_check (argc, argv, 1, sizeof (GtkWindow))
|
||||
#define gtk_init(argc, argv) gtk_init_abi_check (argc, argv, 2, sizeof (GtkWindow), sizeof (GtkBox))
|
||||
#define gtk_init_check(argc, argv) gtk_init_check_abi_check (argc, argv, 2, sizeof (GtkWindow), sizeof (GtkBox))
|
||||
|
||||
#endif
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user