Mercurial > hg > release > icedtea7-2.0
changeset 2462:3ac37175420b
Allow bootstrap build to work with current GNU Classpath CVS.
2011-08-03 Andrew John Hughes <ahughes@redhat.com>
* Makefile.am:
Apply explicit-inner-class-headers patch as required.
* acinclude.m4: Test for PR classpath/45526
explicitly instead of assuming it is present
when the other bugs are (not true with current
Classpath CVS).
* patches/boot/explicit-inner-class-headers.patch:
Split out from javah.patch so as to apply when other
bugs aren't present.
* patches/boot/javah.patch:
Remove above patch.
author | Andrew John Hughes <ahughes@redhat.com> |
---|---|
date | Wed, 03 Aug 2011 17:58:24 +0100 |
parents | e29c130ded8b |
children | a42d0626100f |
files | ChangeLog Makefile.am acinclude.m4 patches/boot/explicit-inner-class-headers.patch patches/boot/javah.patch |
diffstat | 5 files changed, 79 insertions(+), 25 deletions(-) [+] |
line wrap: on
line diff
--- a/ChangeLog Wed Aug 03 11:09:45 2011 +0200 +++ b/ChangeLog Wed Aug 03 17:58:24 2011 +0100 @@ -1,3 +1,17 @@ +2011-08-03 Andrew John Hughes <ahughes@redhat.com> + + * Makefile.am: + Apply explicit-inner-class-headers patch as required. + * acinclude.m4: Test for PR classpath/45526 + explicitly instead of assuming it is present + when the other bugs are (not true with current + Classpath CVS). + * patches/boot/explicit-inner-class-headers.patch: + Split out from javah.patch so as to apply when other + bugs aren't present. + * patches/boot/javah.patch: + Remove above patch. + 2011-08-03 Andrew Haley <aph@redhat.com> Fixed bug #7073913 in src/share/vm/runtime/os.cpp
--- a/Makefile.am Wed Aug 03 11:09:45 2011 +0200 +++ b/Makefile.am Wed Aug 03 17:58:24 2011 +0100 @@ -374,6 +374,10 @@ patches/boot/javah.patch endif +if CP45526_JAVAH +ICEDTEA_BOOT_PATCHES += patches/boot/explicit-inner-class-headers.patch +endif + if CP40616 ICEDTEA_BOOT_PATCHES += patches/boot/pr40616.patch endif
--- a/acinclude.m4 Wed Aug 03 11:09:45 2011 +0200 +++ b/acinclude.m4 Wed Aug 03 17:58:24 2011 +0100 @@ -1277,10 +1277,46 @@ fi ]) rm -f $SUBCLASS $SUPERCLASS $SUBHEADER *.class +AC_CACHE_CHECK([if $JAVAH exhibits Classpath bug 45526], it_cv_cp45526_javah, [ +SRC=Test.java +CLASSFILE=$(echo $SRC|sed 's#\.java##') +HEADER=$(echo $SRC|sed 's#\.java#.h#') +cat << \EOF > $SRC +/* [#]line __oline__ "configure" */ +public class Test +{ + public native void doStuff(); + + public class Inner + { + public native int doMoreStuff(long ptr); + } +} +EOF +if $JAVAC -cp . $JAVACFLAGS $SRC >&AS_MESSAGE_LOG_FD 2>&1; then + if $JAVAH -classpath . $CLASSFILE >&AS_MESSAGE_LOG_FD 2>&1; then + if test -e Test_Inner.h ; then + it_cv_cp45526_javah=no; + else + it_cv_cp45526_javah=yes; + fi + else + AC_MSG_ERROR([The Java header generator $JAVAH failed]) + echo "configure: failed program was:" >&AC_FD_CC + cat $SUBCLASS >&AC_FD_CC + fi +else + AC_MSG_ERROR([The Java compiler $JAVAC failed]) + echo "configure: failed program was:" >&AC_FD_CC + cat $SUBCLASS >&AC_FD_CC +fi +]) +rm -f $SRC *.class *.h cd .. rmdir tmp.$$ AM_CONDITIONAL([CP39408_JAVAH], test x"${it_cv_cp39408_javah}" = "xyes") AM_CONDITIONAL([CP40188_JAVAH], test x"${it_cv_cp40188_javah}" = "xyes") +AM_CONDITIONAL([CP45526_JAVAH], test x"${it_cv_cp45526_javah}" = "xyes") AM_CONDITIONAL([JAVAH_SUPPORTS_X_OPTIONS], test x"${it_cv_javahx}" = "xyes") AC_PROVIDE([$0])dnl ])
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/patches/boot/explicit-inner-class-headers.patch Wed Aug 03 17:58:24 2011 +0100 @@ -0,0 +1,25 @@ +diff -Nru openjdk-boot.orig/jdk/make/common/Rules.gmk openjdk-boot/jdk/make/common/Rules.gmk +--- openjdk-boot.orig/jdk/make/common/Rules.gmk 2009-12-13 20:37:41.000000000 +0000 ++++ openjdk-boot/jdk/make/common/Rules.gmk 2009-12-13 21:11:04.000000000 +0000 +@@ -303,7 +303,11 @@ + $(prep-target) + @$(ECHO) "# Running javah:" + $(JAVAH_CMD) -d $(CLASSHDRDIR)/ \ +- $(CLASSES.export) $(subst $$,\$$,$(EXPORTED_inner)) ++ $(CLASSES.export) ++ $(foreach innerclass,$(subst $$,\$$,$(EXPORTED_inner)), \ ++ $(JAVAH_CMD) \ ++ -o $(CLASSHDRDIR)/$(subst .,_,$(subst \$$,_,$(innerclass))).h \ ++ $(innerclass)) + @$(java-vm-cleanup) + @$(TOUCH) $@ + +diff -Nru openjdk-boot.orig/jdk/make/sun/awt/FILES_export_unix.gmk openjdk-boot/jdk/make/sun/awt/FILES_export_unix.gmk +--- openjdk-boot.orig/jdk/make/sun/awt/FILES_export_unix.gmk 2009-12-04 23:26:35.000000000 +0000 ++++ openjdk-boot/jdk/make/sun/awt/FILES_export_unix.gmk 2009-12-13 21:11:04.000000000 +0000 +@@ -189,3 +189,5 @@ + java/awt/dnd/DnDConstants.java \ + sun/awt/CausedFocusEvent.java + ++EXPORTED_inner = \ ++ sun.java2d.opengl.OGLContext$$OGLContextCaps
--- a/patches/boot/javah.patch Wed Aug 03 11:09:45 2011 +0200 +++ b/patches/boot/javah.patch Wed Aug 03 17:58:24 2011 +0100 @@ -1,28 +1,3 @@ -diff -Nru openjdk-boot.orig/jdk/make/common/Rules.gmk openjdk-boot/jdk/make/common/Rules.gmk ---- openjdk-boot.orig/jdk/make/common/Rules.gmk 2009-12-13 20:37:41.000000000 +0000 -+++ openjdk-boot/jdk/make/common/Rules.gmk 2009-12-13 21:11:04.000000000 +0000 -@@ -303,7 +303,11 @@ - $(prep-target) - @$(ECHO) "# Running javah:" - $(JAVAH_CMD) -d $(CLASSHDRDIR)/ \ -- $(CLASSES.export) $(subst $$,\$$,$(EXPORTED_inner)) -+ $(CLASSES.export) -+ $(foreach innerclass,$(subst $$,\$$,$(EXPORTED_inner)), \ -+ $(JAVAH_CMD) \ -+ -o $(CLASSHDRDIR)/$(subst .,_,$(subst \$$,_,$(innerclass))).h \ -+ $(innerclass)) - @$(java-vm-cleanup) - @$(TOUCH) $@ - -diff -Nru openjdk-boot.orig/jdk/make/sun/awt/FILES_export_unix.gmk openjdk-boot/jdk/make/sun/awt/FILES_export_unix.gmk ---- openjdk-boot.orig/jdk/make/sun/awt/FILES_export_unix.gmk 2009-12-04 23:26:35.000000000 +0000 -+++ openjdk-boot/jdk/make/sun/awt/FILES_export_unix.gmk 2009-12-13 21:11:04.000000000 +0000 -@@ -189,3 +189,5 @@ - java/awt/dnd/DnDConstants.java \ - sun/awt/CausedFocusEvent.java - -+EXPORTED_inner = \ -+ sun.java2d.opengl.OGLContext$$OGLContextCaps diff -Nru openjdk-boot.orig/jdk/src/share/native/sun/java2d/opengl/OGLContext.h openjdk-boot/jdk/src/share/native/sun/java2d/opengl/OGLContext.h --- openjdk-boot.orig/jdk/src/share/native/sun/java2d/opengl/OGLContext.h 2009-12-04 23:33:16.000000000 +0000 +++ openjdk-boot/jdk/src/share/native/sun/java2d/opengl/OGLContext.h 2009-12-13 21:11:04.000000000 +0000