[gtk+/gtk-2-24] build: Fix generation of gtktypefuncs.c with -g3 in CFLAGS



commit 559cb5d8abd55ee8be6ce0992e449a96bb7f5737
Author: Benjamin Otte <otte redhat com>
Date:   Mon Mar 7 17:11:26 2011 +0100

    build: Fix generation of gtktypefuncs.c with -g3 in CFLAGS
    
    With -g3, macros are included in the output, and that caused
    gdk_window_get_type() to be included when it shouldn't be.

 gtk/Makefile.am |    5 +++--
 1 files changed, 3 insertions(+), 2 deletions(-)
---
diff --git a/gtk/Makefile.am b/gtk/Makefile.am
index 85a2ef2..742be50 100644
--- a/gtk/Makefile.am
+++ b/gtk/Makefile.am
@@ -886,9 +886,10 @@ gtktypebuiltins.c: @REBUILD@ $(gtk_public_h_sources) gtktypebuiltins.c.template
 gtktypefuncs.c: @REBUILD@ $(top_srcdir)/gtk/*.h $(top_srcdir)/gdk/*.h Makefile
 	echo '#include <gtk/gtk.h>' > xgen-gtfsrc.c && \
 	  ${CPP} $(DEFS) $(INCLUDES) -DGTK_ENABLE_BROKEN $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) xgen-gtfsrc.c | \
+	  grep '^GType\s*g[td]k_[a-zA-Z0-9_]*_get_type\s*(void)' | \
 	  grep -o '\bg[td]k_[a-zA-Z0-9_]*_get_type\b' | \
-	  sort | uniq | \
-	  sed '{ s/^/*tp++ = /; s/$$/();/; }' > xgen-gtf \
+	  sed '{ s/^/*tp++ = /; s/$$/();/; }' | \
+	  sort > xgen-gtf \
 	&& cp xgen-gtf $@ && rm -f xgen-gtf
 gtktestutils.c: gtktypefuncs.c
 



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