This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Many Failures In libjava Testsuite!


Bryce,

This patch combines both of our ideas and looks pretty clean.

Benefits:

The exportable gc_config.h will only contain THREAD_LOCAL_ALLOC, but
could easily be extended contain more with a simple extension to the grep.

The internal autoheadered configuration file will be named
gc_int_config.h which should stop another library from accidently
including boehm-gc's config.h instead of its own.

The new stampfile logic was duplicated from automakes own stampfile logic.

It's been bootstrapped, but not yet regression tested on i686-pc-linux.

If those pass, OK to install?

[actually attaches patch this time]
KC

2004-11-30  Kelley Cook  <kcook@gcc.gnu.org>

	PR libgcj/18699
	* configure.ac: Rename gc_config.h to gc_int_config.h.
	* gc_config.h.in: Remove.
	* gc_int_config.in: Generate.
	* Makefile.in, configure: Regenerate.
	* include/gc.h: Include gc_int_config.h.
	* include/Makefile.am (gc_config.h): New target.
	(stamp-h2): New stampfile target.
	(all-local): Always build gc_config.h.
	(DISTCLEANFILES): Clean up our mess.
	* include/Makefile.in: Regenerate.
	
diff -Nprud /home/kcook34/gcc-orig/boehm-gc/configure.ac ./configure.ac
--- /home/kcook34/gcc-orig/boehm-gc/configure.ac	2004-11-30 12:21:53.846291700 -0500
+++ ./configure.ac	2004-11-30 13:04:27.501876300 -0500
@@ -468,7 +468,7 @@ else
   multilib_arg=
 fi
 
-AC_CONFIG_HEADERS([include/gc_config.h])
+AC_CONFIG_HEADERS([include/gc_int_config.h])
 
 AC_CONFIG_FILES(Makefile include/Makefile)
 AC_OUTPUT
diff -Nprud /home/kcook34/gcc-orig/boehm-gc/include/Makefile.am ./include/Makefile.am
--- /home/kcook34/gcc-orig/boehm-gc/include/Makefile.am	2002-12-31 12:52:25.000000000 -0500
+++ ./include/Makefile.am	2004-11-30 13:05:22.279003300 -0500
@@ -3,5 +3,20 @@ AUTOMAKE_OPTIONS = foreign
 noinst_HEADERS = gc.h gc_backptr.h gc_local_alloc.h \
   gc_pthread_redirects.h gc_cpp.h
 
+all-local: gc_config.h
 
+gc_config.h: stamp-h2
+	@if test ! -f $@; then \
+	  rm -f stamp-h2; \
+	  $(MAKE) stamp-h2; \
+	else :; fi
 
+stamp-h2: gc_int_config.h
+	@rm -f tmp-gc-config 
+	echo "/* include/gc_config.h  Generated by include/Makefile.in */" > tmp-gc-config
+	echo "" >> tmp-gc-config
+	grep "THREAD_LOCAL_ALLOC" $< >> tmp-gc-config
+	$(SHELL) $(top_srcdir)/../move-if-change tmp-gc-config gc_config.h
+	touch $@
+ 
+DISTCLEANFILES = stamp-h2 gc_config.h
diff -Nprud /home/kcook34/gcc-orig/boehm-gc/include/gc.h ./include/gc.h
--- /home/kcook34/gcc-orig/boehm-gc/include/gc.h	2004-11-30 12:20:51.338279500 -0500
+++ ./include/gc.h	2004-11-30 13:04:47.920626200 -0500
@@ -30,7 +30,7 @@
 
 # define _GC_H
 
-# include <gc_config.h>
+# include <gc_int_config.h>
 # include "gc_config_macros.h"
 
 # if defined(__STDC__) || defined(__cplusplus)

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]