← Back to team overview

openjdk team mailing list archive

Bug#864205: openjdk-8: Please disable jvmtidocs target on m68k

 

Source: openjdk-8
Version: 8u131-b11-2
Severity: important
Tags: patch
User: debian-68k@xxxxxxxxxxxxxxxx
Usertags: m68k

Hi!

While the updated patch in #864180 [1] adds proper m68k support
to openjdk-8, the build currently still fails on m68k during
the jvmtidocs target:

Generating linux_m68k_docs/jvmti.html
/usr/lib/jvm/java-8-openjdk-m68k/bin/java -classpath linux_m68k_docs jvmtiGen -IN /<<PKGBUILDDIR>>/src/hotspot/src/share/vm/prims/jvmti.xml -XSL /<<PKGBUILDDIR>>/src/hotspot/src/share/vm/prims/jvmti.xsl -OUT linux_m68k_docs/jvmti.html
Exception in thread "main" java.lang.OutOfMemoryError: Java heap space
        at java.util.HashMap.resize(HashMap.java:703)
        at java.util.HashMap.putVal(HashMap.java:662)
        at java.util.HashMap.put(HashMap.java:611)
        at java.util.ListResourceBundle.loadLookup(ListResourceBundle.java:204)
        at java.util.ListResourceBundle.handleGetObject(ListResourceBundle.java:130)
        at java.util.ResourceBundle.getObject(ResourceBundle.java:441)
        at java.util.ResourceBundle.getString(ResourceBundle.java:407)
        at com.sun.org.apache.xalan.internal.xsltc.compiler.util.ErrorMsg.getErrorMessage(ErrorMsg.java:312)
        at com.sun.org.apache.xalan.internal.xsltc.compiler.util.ErrorMsg.toString(ErrorMsg.java:285)
        at java.lang.String.valueOf(String.java:2994)
        at java.io.PrintStream.println(PrintStream.java:821)
        at com.sun.org.apache.xalan.internal.xsltc.trax.TransformerImpl.error(TransformerImpl.java:1327)
        at com.sun.org.apache.xalan.internal.xsltc.trax.TransformerImpl.postErrorToListener(TransformerImpl.java:804)
        at com.sun.org.apache.xalan.internal.xsltc.trax.TransformerImpl.transform(TransformerImpl.java:745)
        at com.sun.org.apache.xalan.internal.xsltc.trax.TransformerImpl.transform(TransformerImpl.java:351)
        at jvmtiGen.main(jvmtiGen.java:153)
/<<PKGBUILDDIR>>/src/hotspot/make/linux/makefiles/jvmti.make:105: recipe for target 'linux_m68k_docs/jvmti.html' failed

I have already tried tuning the above command by adding the -Xmx
option to limit the memory usage but without any success. The only
way I managed to get this issue resolved was to disable the jvmtidocs
target on m68k. I don't know though whether Andreas Schwab has found
another solution for this.

I added the following to debian/rules:

diff -Nru openjdk-8-8u131-b11/debian/rules openjdk-8-8u131-b11/debian/rules
--- openjdk-8-8u131-b11/debian/rules    2017-05-16 23:36:46.000000000 +0200
+++ openjdk-8-8u131-b11/debian/rules    2017-06-04 23:14:42.000000000 +0200
@@ -446,6 +446,11 @@
        alpha-float-const.diff
 endif
 
+ifneq (,$(filter $(DEB_HOST_ARCH), m68k))
+  COMMON_PATCHES += \
+       hotspot-disable-jvmtidocs.diff
+endif
+
 ifneq (,$(filter $(DEB_HOST_ARCH), kfreebsd-amd64 kfreebsd-i386))
   COMMON_PATCHES += \
        kfreebsd-support-jdk.diff \

and added the attached patch. Together with the updated patch from
#864180 [1], openjdk-8 builds fine on m68k.

Thanks for consideration!

Adrian

> [1] https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=864180

-- 
 .''`.  John Paul Adrian Glaubitz
: :' :  Debian Developer - glaubitz@xxxxxxxxxx
`. `'   Freie Universitaet Berlin - glaubitz@xxxxxxxxxxxxxxxxxxx
  `-    GPG: 62FF 8A75 84E0 2956 9546  0006 7426 3B37 F5B5 F913
--- a/hotspot/make/linux/Makefile.orig	2017-03-06 20:12:11.000000000 +0100
+++ a/hotspot/make/linux/Makefile	2017-05-08 07:59:49.775242564 +0200
@@ -349,7 +349,7 @@
 # ENABLE_FULL_DEBUG_SYMBOLS value is used.
 docs: checks
 	$(QUIETLY) mkdir -p $(SUBDIR_DOCS)
-	$(MAKE) -f $(GAMMADIR)/make/$(OSNAME)/makefiles/jvmti.make $(MFLAGS) $(BUILDTREE_VARS) JvmtiOutDir=$(SUBDIR_DOCS) BUILD_FLAVOR=product jvmtidocs
+	#$(MAKE) -f $(GAMMADIR)/make/$(OSNAME)/makefiles/jvmti.make $(MFLAGS) $(BUILDTREE_VARS) JvmtiOutDir=$(SUBDIR_DOCS) BUILD_FLAVOR=product jvmtidocs
 
 # Synonyms for win32-like targets.
 compiler2:  debug product
--- a/hotspot/make/linux/makefiles/defs.make.orig	2017-03-06 20:12:11.000000000 +0100
+++ a/hotspot/make/linux/makefiles/defs.make	2017-05-08 11:28:50.001500588 +0200
@@ -234,7 +234,7 @@
 # Library suffix
 LIBRARY_SUFFIX=so
 
-EXPORT_LIST += $(EXPORT_DOCS_DIR)/platform/jvmti/jvmti.html
+#EXPORT_LIST += $(EXPORT_DOCS_DIR)/platform/jvmti/jvmti.html
 
 # client and server subdirectories have symbolic links to ../libjsig.so
 EXPORT_LIST += $(EXPORT_JRE_LIB_ARCH_DIR)/libjsig.$(LIBRARY_SUFFIX)