From ernst@trillian.euronet.nl  Tue May  7 04:11:16 2002
Return-Path: <ernst@trillian.euronet.nl>
Received: from trillian.euronet.nl (trillian.euronet.nl [194.134.109.52])
	by hub.freebsd.org (Postfix) with ESMTP id 93BAB37B404
	for <FreeBSD-gnats-submit@freebsd.org>; Tue,  7 May 2002 04:11:15 -0700 (PDT)
Received: (from root@localhost)
	by trillian.euronet.nl (8.11.5/8.11.5) id g47BVUW00260;
	Tue, 7 May 2002 13:31:30 +0200 (CEST)
	(envelope-from ernst)
Message-Id: <200205071131.g47BVUW00260@trillian.euronet.nl>
Date: Tue, 7 May 2002 13:31:30 +0200 (CEST)
From: Ernst de Haan <znerd@freebsd.org>
Reply-To: Ernst de Haan <znerd@freebsd.org>
To: FreeBSD-gnats-submit@freebsd.org
Cc:
Subject: Library libhpi.so not found when running java
X-Send-Pr-Version: 3.113
X-GNATS-Notify:

>Number:         37818
>Category:       java
>Synopsis:       Library libhpi.so not found when running java
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    glewis
>State:          closed
>Quarter:        
>Keywords:       
>Date-Required:  
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Tue May 07 04:20:01 PDT 2002
>Closed-Date:    Mon Oct 14 17:06:07 PDT 2002
>Last-Modified:  Mon Oct 14 17:06:07 PDT 2002
>Originator:     Charlie &
>Release:        FreeBSD 4.4-20010815-RC1 i386
>Organization:
FreeBSD
>Environment:
System: FreeBSD reseller.wanadoo.nl 4.4-20010815-RC1 FreeBSD 4.4-20010815-RC1 #0: Thu Aug 16 06:35:35 GMT 2001 murray@scrub.lab.nuxi.com:/usr/src/sys/compile/GENERIC i386
>Description:
When I try to start orion using orionctl, I get the following error message:

/usr/local/linux-jdk1.3.1/bin/i386/green_threads/java: error in loading shared libraries: libhpi.so: cannot open shared object file: No such file or directory

I'm using the java/linux-jdk13 (linux-jdk-1.3.1.03)

The weird thing is this:

su-2.05$ /usr/local/linux-jdk1.3.1/bin/i386/green_threads/java -version
/usr/local/linux-jdk1.3.1/bin/i386/green_threads/java: error in loading shared libraries: libhpi.so: cannot open shared object file: No such file or directory
su-2.05$ /usr/local/linux-jdk1.3.1/bin/java -version
java version "1.3.1_03"
Java(TM) 2 Runtime Environment, Standard Edition (build 1.3.1_03-b03)
Classic VM (build 1.3.1_03-b03, green threads, nojit)
su-2.05$
>How-To-Repeat:
>Fix:
>Release-Note:
>Audit-Trail:
Responsible-Changed-From-To: freebsd-ports->glewis 
Responsible-Changed-By: znerd 
Responsible-Changed-When: Tue May 7 04:44:26 PDT 2002 
Responsible-Changed-Why:  
Over to Greg Lewis because I expect him to be able to 
analyse the problem. 

http://www.freebsd.org/cgi/query-pr.cgi?pr=37818 

From: Ernst de Haan <ernsth@nl.euro.net>
To: freebsd-gnats-submit@FreeBSD.org, glewis@FreeBSD.org
Cc:  
Subject: Re: ports/37818: Library libhpi.so not found when running java
Date: Mon, 13 May 2002 18:07:13 +0200

 This happens with the native JDK as well:
 
 zaphod# /usr/local/linux-jdk1.3.1/jre/bin/i386/green_threads/java
 /usr/local/linux-jdk1.3.1/jre/bin/i386/green_threads/java: error while loading 
 shared libraries: libhpi.so: cannot load shared object file: No such file or 
 directory
 zaphod# /usr/local/jdk1.3.1/jre/bin/i386/green_threads/java
 /usr/libexec/ld-elf.so.1: Shared object "libhpi.so" not found
 zaphod#
 
 Any ideas?

From: Greg Lewis <glewis@eyesbeyond.com>
To: Ernst de Haan <ernsth@nl.euro.net>
Cc: freebsd-gnats-submit@FreeBSD.org, glewis@FreeBSD.org
Subject: Re: ports/37818: Library libhpi.so not found when running java
Date: Wed, 15 May 2002 12:46:15 +0930

 On Mon, May 13, 2002 at 06:07:13PM +0200, Ernst de Haan wrote:
 > This happens with the native JDK as well:
 > 
 > zaphod# /usr/local/linux-jdk1.3.1/jre/bin/i386/green_threads/java
 > /usr/local/linux-jdk1.3.1/jre/bin/i386/green_threads/java: error while loading 
 > shared libraries: libhpi.so: cannot load shared object file: No such file or 
 > directory
 > zaphod# /usr/local/jdk1.3.1/jre/bin/i386/green_threads/java
 > /usr/libexec/ld-elf.so.1: Shared object "libhpi.so" not found
 > zaphod#
 
 Lots.  Whatever orionctl is doing that means it tries to execute this
 directly needs to stop.  One executes /usr/local/jdk1.3.1/jre/bin/java
 instead of /usr/local/jdk1.3.1/jre/bin/i386/green_threads/java for a
 reason.  That reason is that /usr/local/jdk1.3.1/jre/bin/java is
 actually a shell script which, among other things, sets up things
 like LD_LIBRARY_PATH so that all the shared libraries can be found
 and then exec's the appropriate binary.  If you absolutely have to
 execute the binary directly yourself, then you also need to do all
 this set up yourself.  Otherwise you get the errors above.
 
 This situation has changed in 1.4, mainly because there are no longer
 multiple threading subsystems.
 
 Bad orionctl, no biscuit.
 
 -- 
 Greg Lewis                            Email : glewis@eyesbeyond.com
 Eyes Beyond                           Web   : http://www.eyesbeyond.com
 Information Technology
 

From: Ernst de Haan <ernsth@nl.euro.net>
To: Greg Lewis <glewis@eyesbeyond.com>
Cc: freebsd-gnats-submit@FreeBSD.org, glewis@FreeBSD.org
Subject: Re: ports/37818: Library libhpi.so not found when running java
Date: Wed, 15 May 2002 09:19:13 +0200

 Greg,
 
 > Lots.  Whatever orionctl is doing that means it tries to execute this
 > directly needs to stop.  One executes /usr/local/jdk1.3.1/jre/bin/java
 > instead of /usr/local/jdk1.3.1/jre/bin/i386/green_threads/java for a
 
 Yeah, well, I do let the daemonctl execute /usr/local/jdk1.3.1/jre/bin/java, 
 that's the problem :-\
 
 ernst@zaphod$ grep execl ports/www/orion/work/daemonctl_.c
                 execl("/usr/local/jdk1.3.1/bin/java", 
 "/usr/local/jdk1.3.1/bin/java", "-jar",  "orion.jar",  NULL);
 ernst@zaphod$
 
 So it's a bit of a mistery to me...
 
 
 Ernst
 
 -- 
 Ernst de Haan
 EuroNet Internet B.V.
 
     "Come to me all who are weary and burdened
         and I will give you rest" -- Jesus Christ
State-Changed-From-To: open->closed 
State-Changed-By: glewis 
State-Changed-When: Mon Sep 16 20:17:21 PDT 2002 
State-Changed-Why:  
Judging from the mail on freebsd-java a solution for this 
had been found and was linked to the set{u,g}id'ness of the 
daemonctl program. 

http://www.freebsd.org/cgi/query-pr.cgi?pr=37818 

From: Ernst de Haan <ernst.dehaan@nl.wanadoo.com>
To: freebsd-gnats-submit@FreeBSD.org
Cc:  
Subject: Re: ports/37818: Library libhpi.so not found when running java
Date: Tue, 17 Sep 2002 10:12:47 +0200

 Greg,
 
 I think this one should be re-opened for now because the problem is not 
 actually solved. A solution was proposed on freebsd-java by Ari Suutari. I 
 initially committed this, but Kris pointed out that it should be reviewed 
 by audit. I've sent a request for review to audit. No response so far...
 
 Ernst
 
 -- 
 Ernst de Haan
 Development Team Leader
 Wanadoo Nederland B.V.
 
     "Come to me all who are weary and burdened
         and I will give you rest" -- Jesus Christ
State-Changed-From-To: closed->feedback 
State-Changed-By: glewis 
State-Changed-When: Tue Sep 17 08:09:26 PDT 2002 
State-Changed-Why:  
Re-opening at Ernst's request.  Feedback seems the most 
appropriate state given that there is a proposed solution 
which is awaiting feedback. 

http://www.freebsd.org/cgi/query-pr.cgi?pr=37818 

From: Ernst de Haan <ernst.dehaan@nl.wanadoo.com>
To: freebsd-gnats-submit@FreeBSD.org, znerd@FreeBSD.org
Cc:  
Subject: Re: java/37818: Library libhpi.so not found when running java
Date: Fri, 11 Oct 2002 11:20:58 +0200

 The patch has been committed, so the PR can be closed.
 
 --
 Ernst
State-Changed-From-To: feedback->closed 
State-Changed-By: glewis 
State-Changed-When: Mon Oct 14 17:05:49 PDT 2002 
State-Changed-Why:  
As Ernst said, the patch has been committed. 

http://www.freebsd.org/cgi/query-pr.cgi?pr=37818 
>Unformatted:
