Commit cca8dd63 authored by Matthias Clasen's avatar Matthias Clasen Committed by Matthias Clasen
Browse files

Make PLT-reduction work with gcc4, and don't include everything in

2005-03-20  Matthias Clasen  <mclasen@redhat.com>

	Make PLT-reduction work with gcc4, and don't include
	everything in gdkalias.h:

	* gtk/grk.symbols: Group symbols by header and source file.
	* gtk/makegtkalias.pl: Protect definitions by the same
	preprocessor symbols used to guard the headers. Move
	the alias declarations to a separate file which is
	produced when calling makegtkalias.pl -def
	* gdk/Makefile.am (gtkaliasdef.c): Add a rule to generate
	this file.
	* gtk/*.c: Include gtkalias.h after the other headers,
	include gtkaliasdef.c at the bottom.
	* gtk/*.h: Small cleanups.
parent b39b0bfc
2005-03-20 Matthias Clasen <mclasen@redhat.com>
Make PLT-reduction work with gcc4, and don't include
everything in gdkalias.h:
* gtk/grk.symbols: Group symbols by header and source file.
* gtk/makegtkalias.pl: Protect definitions by the same
preprocessor symbols used to guard the headers. Move
the alias declarations to a separate file which is
produced when calling makegtkalias.pl -def
* gdk/Makefile.am (gtkaliasdef.c): Add a rule to generate
this file.
* gtk/*.c: Include gtkalias.h after the other headers,
include gtkaliasdef.c at the bottom.
* gtk/*.h: Small cleanups.
Fri Mar 18 23:59:49 2005 Soeren Sandmann <sandmann@redhat.com>
* gtk/gtkmenutoolbutton.c (arrow_button_button_press_event_cb):
......
2005-03-20 Matthias Clasen <mclasen@redhat.com>
Make PLT-reduction work with gcc4, and don't include
everything in gdkalias.h:
* gtk/grk.symbols: Group symbols by header and source file.
* gtk/makegtkalias.pl: Protect definitions by the same
preprocessor symbols used to guard the headers. Move
the alias declarations to a separate file which is
produced when calling makegtkalias.pl -def
* gdk/Makefile.am (gtkaliasdef.c): Add a rule to generate
this file.
* gtk/*.c: Include gtkalias.h after the other headers,
include gtkaliasdef.c at the bottom.
* gtk/*.h: Small cleanups.
Fri Mar 18 23:59:49 2005 Soeren Sandmann <sandmann@redhat.com>
* gtk/gtkmenutoolbutton.c (arrow_button_button_press_event_cb):
......
2005-03-20 Matthias Clasen <mclasen@redhat.com>
Make PLT-reduction work with gcc4, and don't include
everything in gdkalias.h:
* gtk/grk.symbols: Group symbols by header and source file.
* gtk/makegtkalias.pl: Protect definitions by the same
preprocessor symbols used to guard the headers. Move
the alias declarations to a separate file which is
produced when calling makegtkalias.pl -def
* gdk/Makefile.am (gtkaliasdef.c): Add a rule to generate
this file.
* gtk/*.c: Include gtkalias.h after the other headers,
include gtkaliasdef.c at the bottom.
* gtk/*.h: Small cleanups.
Fri Mar 18 23:59:49 2005 Soeren Sandmann <sandmann@redhat.com>
* gtk/gtkmenutoolbutton.c (arrow_button_button_press_event_cb):
......
......@@ -75,10 +75,12 @@ uninstall-ms-lib:
endif
gtk.def: gtk.symbols
(echo -e EXPORTS; $(CPP) -P -DINCLUDE_VARIABLES -DG_OS_WIN32 - <$(srcdir)/gtk.symbols | sed -e '/^$$/d' -e 's/^/ /' -e 's/G_GNUC_[^ ]*//g') > gtk.def
(echo -e EXPORTS; $(CPP) -P -DINCLUDE_VARIABLES -DG_OS_WIN32 -DALL_FILES - <$(srcdir)/gtk.symbols | sed -e '/^$$/d' -e 's/^/ /' -e 's/G_GNUC_[^ ]*//g') > gtk.def
gtkalias.h: gtk.symbols
$(PERL) $(srcdir)/makegtkalias.pl < $(srcdir)/gtk.symbols > gtkalias.h
gtkaliasdef.c: gtk.symbols
$(PERL) $(srcdir)/makegtkalias.pl -def < $(srcdir)/gtk.symbols > gtkaliasdef.c
if OS_LINUX
TESTS = abicheck.sh
......@@ -553,6 +555,7 @@ gtk_built_private_headers = \
gtkmarshalers.h
gtk_built_sources = \
gtkaliasdef.c \
gtktypebuiltins.c \
gtkmarshalers.c \
gtkmarshalers.h \
......@@ -636,7 +639,8 @@ stamp-gtktypebuiltins.h: @REBUILD@ $(gtk_public_h_sources) Makefile
&& echo timestamp > $(@F)
gtktypebuiltins.c: @REBUILD@ $(gtk_public_h_sources) Makefile
( cd $(srcdir) && glib-mkenums \
--fhead "#undef GTK_DISABLE_DEPRECATED\n#define GTK_ENABLE_BROKEN\n#include \"gtkalias.h\"\n#include \"gtk.h\"\n#include \"gtkprivate.h\"" \
--fhead "#undef GTK_DISABLE_DEPRECATED\n#define GTK_ENABLE_BROKEN\n#include \"gtk.h\"\n#include \"gtkprivate.h\"\n#include \"gtkalias.h\"\n" \
--ftail "#define __GTK_TYPE_BUILTINS_C__\n#include \"gtkaliasdef.c\"\n" \
--fprod "\n/* enumerations from \"@filename@\" */" \
--vhead "GType\n@enum_name@_get_type (void)\n{\n static GType etype = 0;\n if (etype == 0) {\n static const G@Type@Value values[] = {" \
--vprod " { @VALUENAME@, \"@VALUENAME@\", \"@valuenick@\" }," \
......
#! /bin/sh
cpp -P -DG_OS_UNIX -DGTK_WINDOWING_X11 ${srcdir:-.}/gtk.symbols | sed -e '/^$/d' -e 's/ G_GNUC.*$//' -e 's/ PRIVATE//' | sort > expected-abi
cpp -P -DG_OS_UNIX -DGTK_WINDOWING_X11 -DALL_FILES ${srcdir:-.}/gtk.symbols | sed -e '/^$/d' -e 's/ G_GNUC.*$//' -e 's/ PRIVATE//' | sort > expected-abi
nm -D .libs/libgtk-x11-2.0.so | grep " T " | cut -d ' ' -f 3 | sort > actual-abi
diff -u expected-abi actual-abi && rm expected-abi actual-abi
......@@ -41,8 +41,6 @@
#define _GNU_SOURCE
#endif
#include "gtkalias.h"
static gunichar
get_char (const char **str)
{
......
This diff is collapsed.
......@@ -32,8 +32,6 @@
#include <gdk/gdkkeysyms.h>
#include "gtkalias.h"
#include "gtkaboutdialog.h"
#include "gtkbutton.h"
#include "gtkbbox.h"
......@@ -51,6 +49,8 @@
#include "gtkiconfactory.h"
#include "gtkintl.h"
#include "gtkalias.h"
#include <string.h>
typedef struct _GtkAboutDialogPrivate GtkAboutDialogPrivate;
......@@ -2219,3 +2219,6 @@ gtk_show_about_dialog (GtkWindow *parent,
gtk_window_present (GTK_WINDOW (dialog));
}
#define __GTK_ABOUT_DIALOG_C__
#include "gtkaliasdef.c"
......@@ -28,7 +28,6 @@
#include <string.h>
#include <stdlib.h>
#include "gtkalias.h"
#include "gtkaccelgroup.h"
#include "gtkaccellabel.h" /* For _gtk_accel_label_class_get_accelerator_label */
#include "gtkaccelmap.h"
......@@ -36,6 +35,7 @@
#include "gtkmain.h" /* For _gtk_boolean_handled_accumulator */
#include "gdk/gdkkeysyms.h"
#include "gtkmarshalers.h"
#include "gtkalias.h"
/* --- prototypes --- */
......@@ -1246,3 +1246,6 @@ gtk_accelerator_get_default_mod_mask (void)
{
return default_accel_mod_mask;
}
#define __GTK_ACCEL_GROUP_C__
#include "gtkaliasdef.c"
......@@ -30,11 +30,11 @@
#include <config.h>
#include <string.h>
#include "gtkalias.h"
#include "gtkaccellabel.h"
#include "gtkaccelmap.h"
#include "gtkmain.h"
#include "gtkintl.h"
#include "gtkalias.h"
enum {
PROP_0,
......@@ -636,3 +636,6 @@ gtk_accel_label_refetch (GtkAccelLabel *accel_label)
return FALSE;
}
#define __GTK_ACCEL_LABEL_C__
#include "gtkaliasdef.c"
......@@ -19,11 +19,11 @@
#include <config.h>
#include "gtkalias.h"
#include "gtkaccelmap.h"
#include "gtkmarshalers.h"
#include "gtkwindow.h" /* in lack of GtkAcceleratable */
#include "gtkalias.h"
#include <glib/gstdio.h>
......@@ -1028,3 +1028,6 @@ gtk_accel_map_save (const gchar *file_name)
}
#endif
#define __GTK_ACCEL_MAP_C__
#include "gtkaliasdef.c"
......@@ -20,9 +20,9 @@
#include <config.h>
#include <string.h>
#include "gtkalias.h"
#include "gtkwidget.h"
#include "gtkaccessible.h"
#include "gtkalias.h"
static void gtk_accessible_class_init (GtkAccessibleClass *klass);
......@@ -93,3 +93,6 @@ gtk_accessible_real_connect_widget_destroyed (GtkAccessible *accessible)
&accessible->widget);
}
}
#define __GTK_ACCESSIBLE_C__
#include "gtkaliasdef.c"
......@@ -23,9 +23,7 @@
#include <atk/atk.h>
#include <gtk/gtkwidget.h>
#ifdef __cplusplus
extern "C" {
#endif /* __cplusplus */
G_BEGIN_DECLS
#define GTK_TYPE_ACCESSIBLE (gtk_accessible_get_type ())
#define GTK_ACCESSIBLE(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), GTK_TYPE_ACCESSIBLE, GtkAccessible))
......@@ -69,10 +67,7 @@ GType gtk_accessible_get_type (void) G_GNUC_CONST;
void gtk_accessible_connect_widget_destroyed (GtkAccessible *accessible);
#ifdef __cplusplus
}
#endif /* __cplusplus */
G_END_DECLS
#endif /* __GTK_ACCESSIBLE_H__ */
......
......@@ -30,7 +30,6 @@
#include <config.h>
#include "gtkalias.h"
#include "gtkaction.h"
#include "gtkactiongroup.h"
#include "gtkaccellabel.h"
......@@ -45,6 +44,7 @@
#include "gtktearoffmenuitem.h"
#include "gtktoolbutton.h"
#include "gtktoolbar.h"
#include "gtkalias.h"
#define GTK_ACTION_GET_PRIVATE(obj) (G_TYPE_INSTANCE_GET_PRIVATE ((obj), GTK_TYPE_ACTION, GtkActionPrivate))
......@@ -1574,3 +1574,6 @@ gtk_action_disconnect_accelerator (GtkAction *action)
gtk_accel_group_disconnect (action->private_data->accel_group,
action->private_data->accel_closure);
}
#define __GTK_ACTION_C__
#include "gtkaliasdef.c"
......@@ -30,7 +30,6 @@
#include <config.h>
#include "gtkalias.h"
#include "gtkactiongroup.h"
#include "gtkstock.h"
#include "gtktoggleaction.h"
......@@ -38,6 +37,7 @@
#include "gtkaccelmap.h"
#include "gtkmarshalers.h"
#include "gtkintl.h"
#include "gtkalias.h"
#define GTK_ACTION_GROUP_GET_PRIVATE(obj) (G_TYPE_INSTANCE_GET_PRIVATE ((obj), GTK_TYPE_ACTION_GROUP, GtkActionGroupPrivate))
......@@ -1120,3 +1120,6 @@ _gtk_action_group_emit_post_activate (GtkActionGroup *action_group,
{
g_signal_emit (action_group, action_group_signals[POST_ACTIVATE], 0, action);
}
#define __GTK_ACTION_GROUP_C__
#include "gtkaliasdef.c"
......@@ -25,10 +25,10 @@
*/
#include <config.h>
#include "gtkalias.h"
#include "gtkadjustment.h"
#include "gtkintl.h"
#include "gtkmarshalers.h"
#include "gtkalias.h"
enum
{
......@@ -421,3 +421,6 @@ gtk_adjustment_clamp_page (GtkAdjustment *adjustment,
if (need_emission)
gtk_adjustment_value_changed (adjustment);
}
#define __GTK_ADJUSTMENT_C__
#include "gtkaliasdef.c"
......@@ -25,9 +25,9 @@
*/
#include <config.h>
#include "gtkalias.h"
#include "gtkalignment.h"
#include "gtkintl.h"
#include "gtkalias.h"
enum {
PROP_0,
......@@ -619,3 +619,6 @@ gtk_alignment_get_padding (GtkAlignment *alignment,
if(padding_right)
*padding_right = priv->padding_right;
}
#define __GTK_ALIGNMENT_C__
#include "gtkaliasdef.c"
......@@ -26,9 +26,9 @@
#include <config.h>
#include <math.h>
#include "gtkalias.h"
#include "gtkarrow.h"
#include "gtkintl.h"
#include "gtkalias.h"
#define MIN_ARROW_SIZE 15
......@@ -288,3 +288,6 @@ gtk_arrow_expose (GtkWidget *widget,
return FALSE;
}
#define __GTK_ARROW_C__
#include "gtkaliasdef.c"
......@@ -30,9 +30,9 @@
*/
#include <config.h>
#include "gtkalias.h"
#include "gtkaspectframe.h"
#include "gtkintl.h"
#include "gtkalias.h"
enum {
PROP_0,
......@@ -335,3 +335,6 @@ gtk_aspect_frame_compute_child_allocation (GtkFrame *frame,
else
parent_class->compute_child_allocation (frame, child_allocation);
}
#define __GTK_ASPECT_FRAME_C__
#include "gtkaliasdef.c"
......@@ -32,10 +32,7 @@
#include <gtk/gtkbin.h>
#include <gtk/gtkframe.h>
#ifdef __cplusplus
extern "C" {
#endif /* __cplusplus */
G_BEGIN_DECLS
#define GTK_TYPE_ASPECT_FRAME (gtk_aspect_frame_get_type ())
#define GTK_ASPECT_FRAME(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), GTK_TYPE_ASPECT_FRAME, GtkAspectFrame))
......@@ -79,9 +76,6 @@ void gtk_aspect_frame_set (GtkAspectFrame *aspect_frame,
gboolean obey_child);
#ifdef __cplusplus
}
#endif /* __cplusplus */
G_END_DECLS
#endif /* __GTK_ASPECT_FRAME_H__ */
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment