Upstream-Status: Pending

Pass CC & CFLAGS vars so that tune parameters get used.
This fixes compilation with x32 toolchain.

Received this patch from H.J. Lu <hjl.tools@gmail.com>
Signed-Off-By: Nitin A Kamble <nitin.a.kamble@intel.com> 2011/07/13

Index: glib-2.30.0/glib/Makefile.am
===================================================================
--- glib-2.30.0.orig/glib/Makefile.am
+++ glib-2.30.0/glib/Makefile.am
@@ -359,10 +359,10 @@ INSTALL_PROGS=
 
 if ENABLE_DTRACE
 glib_probes.h: glib_probes.d Makefile
-	$(AM_V_GEN) $(DTRACE) -C -h -s $< -o $@.tmp
+	$(AM_V_GEN) CFLAGS="$(CFLAGS)" $(DTRACE) -C -h -s $< -o $@.tmp
 	@$(SED) -e "s,define STAP_HAS_SEMAPHORES 1,undef STAP_HAS_SEMAPHORES," < $@.tmp > $@ && rm -f $@.tmp
 glib_probes.o: glib_probes.d Makefile
-	$(AM_V_GEN) $(DTRACE) -G -s $< -o $@
+	$(AM_V_GEN) CFLAGS="$(CFLAGS)" $(DTRACE) -G -s $< -o $@
 BUILT_SOURCES += glib_probes.h glib_probes.o
 CLEANFILES += glib_probes.h glib_probes.h.tmp
 libglib_2_0_la_LIBADD += glib_probes.o
Index: glib-2.30.0/gobject/Makefile.am
===================================================================
--- glib-2.30.0.orig/gobject/Makefile.am
+++ glib-2.30.0/gobject/Makefile.am
@@ -141,10 +141,10 @@ gobject_c_sources = \
 
 if ENABLE_DTRACE
 gobject_probes.h: gobject_probes.d Makefile
-	$(AM_V_GEN) $(DTRACE) -C -h -s $< -o $@.tmp
+	$(AM_V_GEN) CFLAGS="$(CFLAGS)" $(DTRACE) -C -h -s $< -o $@.tmp
 	@$(SED) -e "s,define STAP_HAS_SEMAPHORES 1,undef STAP_HAS_SEMAPHORES," < $@.tmp > $@ && rm -f $@.tmp
 gobject_probes.o: gobject_probes.d Makefile
-	$(AM_V_GEN) $(DTRACE) -G -s $< -o $@
+	$(AM_V_GEN) CFLAGS="$(CFLAGS)" $(DTRACE) -G -s $< -o $@
 BUILT_SOURCES += gobject_probes.h gobject_probes.o
 CLEANFILES += gobject_probes.h
 libgobject_2_0_la_LIBADD += gobject_probes.o
