NetBSD Problem Report #44221

From www@NetBSD.org  Sun Dec 12 09:52:54 2010
Return-Path: <www@NetBSD.org>
Received: from mail.netbsd.org (mail.netbsd.org [204.152.190.11])
	by www.NetBSD.org (Postfix) with ESMTP id 61C4F63B883
	for <gnats-bugs@gnats.NetBSD.org>; Sun, 12 Dec 2010 09:52:54 +0000 (UTC)
Message-Id: <20101212095254.4339463B87A@www.NetBSD.org>
Date: Sun, 12 Dec 2010 09:52:54 +0000 (UTC)
From: noud4@home.nl
Reply-To: noud4@home.nl
To: gnats-bugs@NetBSD.org
Subject: kaffe builds but is unusable (to bootstrap wip/jdk15)
X-Send-Pr-Version: www-1.0

>Number:         44221
>Category:       pkg
>Synopsis:       kaffe builds but is unusable (to bootstrap wip/jdk15)
>Confidential:   no
>Severity:       serious
>Priority:       low
>Responsible:    tonio
>State:          closed
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Sun Dec 12 09:55:00 +0000 2010
>Closed-Date:    Tue Apr 14 13:17:22 +0000 2020
>Last-Modified:  Tue Apr 14 13:17:22 +0000 2020
>Originator:     B ICT A.P. deBrouwer Jr.
>Release:        i386 5.0.2
>Organization:
-none-
>Environment:
NetBSD 10.0.2.17 5.0.2 NetBSD 5.0.2 (GENERIC.IP4) #2: Sun Nov 14 16:18:05 CET 2010  root@h12.hosts:/obj/sys/arch/i386/compile/GENERIC.IP4 i386
>Description:
wip/jdk15 being resurrected, build using kaffe on DragonFly
did succeed but a build on NetBSD/i386 and amd64 didn't.

Francois Tigeot <ftigeot@wolfpond.org> did tell me the included needed fix.
>How-To-Repeat:
build (resurrected) wip/jdk15 using kaffe to bootstrap from
and notice the jdk15 build breaking:

Internal error: caught an unexpected exception.
Please check your CLASSPATH and your installation.
java/lang/NullPointerException
   at gnu.classpath.SystemProperties.getProperty (SystemProperties.java:123)
   at java.lang.VMClassLoader.<clinit> (VMClassLoader.java:83)
   at java.lang.ClassLoader$StaticData.<clinit> (ClassLoader.java:154)
   at java.lang.ClassLoader.getSystemClassLoader (ClassLoader.java:797)
   at gnu.classpath.VMSystemProperties.postInit (VMSystemProperties.java:native)
   at gnu.classpath.SystemProperties.<clinit> (SystemProperties.java:114)
   at java.lang.Runtime.<init> (Runtime.java:100)
   at java.lang.Runtime.<clinit> (Runtime.java:88)
   at java.lang.System.loadLibrary (System.java:560)
   at gnu.java.nio.channels.FileChannelImpl.<clinit> (FileChannelImpl.java:86)
   at java.io.FileDescriptor.<clinit> (FileDescriptor.java:63)
   at java.lang.VMSystem.makeStandardInputStream (VMSystem.java:191)
   at java.lang.System.<clinit> (System.java:74)
   at java.lang.Object.hashCode (Object.java:174)
   at java.util.Hashtable.hash (Hashtable.java:816)
   at java.util.Hashtable.put (Hashtable.java:426)
   at java.security.Permissions.add (Permissions.java:112)
[1]   Abort trap (core dumped) /pkg_comp/obj/pk...
gmake[2]: *** [../generated/includeDB.current] Error 134
gmake[2]: Leaving directory `/pkg_comp/obj/pkgsrc/wip/jdk15/default/control/build/bsd-i586/hotspot-i586/tmp/bsd_i486_compiler2/product'
gmake[1]: *** [product] Error 2
gmake[1]: Leaving directory `/pkg_comp/obj/pkgsrc/wip/jdk15/default/control/build/bsd-i586/hotspot-i586/tmp'
gmake: *** [product] Error 2
*** Error code 2


conform my understanding Francois on DragonFly is using gcc 4.4.2 and he suspects gcc 3.4 should also work.
on NetBSD however the build breaks as well, if using gcc44-4.4.4nb1:

cd ../generated;   /pkg_comp/obj/pkgsrc/wip/jdk15/default/bin/java -classpath . MakeDeps diffs UnixPlatform platform.current includeDB.current /pkg_comp/obj/pkgsrc/wip/jdk15/default/hotspot/build/bsd/platform_i486 includeDB 
java.lang.ClassNotFoundException: MakeDeps not found in java.lang.ClassLoader$1{urls=[file:/pkg_comp/obj/pkgsrc/wip/jdk15/default/control/build/bsd-i586/hotspot-i586/tmp/bsd_i486_compiler2/generated/./], parent=null}
gmake[2]: *** [../generated/includeDB.current] Error 1
gmake[2]: Leaving directory `/pkg_comp/obj/pkgsrc/wip/jdk15/default/control/build/bsd-i586/hotspot-i586/tmp/bsd_i486_compiler2/product'
gmake[1]: *** [product] Error 2
gmake[1]: Leaving directory `/pkg_comp/obj/pkgsrc/wip/jdk15/default/control/build/bsd-i586/hotspot-i586/tmp'
gmake: *** [product] Error 2
*** Error code 2


i'm unsure the start this kaffe problem but suspect
!empty(MACHINE_PLATFORM:MNetBSD-4*) || !empty(MACHINE_PLATFORM:MNetBSD-5*)
i.s.o.
!empty(MACHINE_PLATFORM:MNetBSD-5*)

>Fix:
--- /usr/pkgsrc/lang/kaffe/Makefile	2009-12-16 00:41:45.000000000 +0100
+++ /usr/pkgsrc/lang/kaffe/Makefile.new	2010-12-12 01:35:06.000000000 +0100
@@ -29,5 +29,14 @@
 post-install:
 	${INSTALL_DATA} ${WRKSRC}/license.terms ${DESTDIR}${JAVA_HOME}

+.include "../../mk/bsd.prefs.mk"
+
+.if ${OPSYS} == "DragonFly"  || (!empty(MACHINE_PLATFORM:MNetBSD-4*) || !empty(MACHINE_PLATFORM:MNetBSD-5*))
+GCC_REQD+=		3.4
+USE_PKGSRC_GCC=		yes
+CFLAGS+=		-O0
+.endif
+.include "../../mk/compiler.mk"
+
 .include "../../mk/java-env.mk"
 .include "../../mk/bsd.pkg.mk"

>Release-Note:

>Audit-Trail:

Responsible-Changed-From-To: pkg-manager->tonio
Responsible-Changed-By: wiz@NetBSD.org
Responsible-Changed-When: Sun, 12 Dec 2010 10:53:05 +0000
Responsible-Changed-Why:
Over to maintainer


State-Changed-From-To: open->closed
State-Changed-By: maya@NetBSD.org
State-Changed-When: Tue, 14 Apr 2020 13:17:22 +0000
State-Changed-Why:
These compiler versions are now very obsolete, adding -O0 for them now seems like a bad idea. Closing as a stale bug report, sorry your patch was not addressed at the time.


>Unformatted:

NetBSD Home
NetBSD PR Database Search

(Contact us) $NetBSD: gnats-precook-prs,v 1.4 2018/12/21 14:20:20 maya Exp $
$NetBSD: gnats_config.sh,v 1.9 2014/08/02 14:16:04 spz Exp $
Copyright © 1994-2017 The NetBSD Foundation, Inc. ALL RIGHTS RESERVED.