From owner-freebsd-java@FreeBSD.ORG Mon Jul 9 11:56:54 2007 Return-Path: X-Original-To: freebsd-java@freebsd.org Delivered-To: freebsd-java@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 4EFA816A41F for ; Mon, 9 Jul 2007 11:56:54 +0000 (UTC) (envelope-from ronald-freebsd8@klop.yi.org) Received: from smtp-out1.tiscali.nl (smtp-out1.tiscali.nl [195.241.79.176]) by mx1.freebsd.org (Postfix) with ESMTP id 1879D13C43E for ; Mon, 9 Jul 2007 11:56:53 +0000 (UTC) (envelope-from ronald-freebsd8@klop.yi.org) Received: from [82.171.39.195] (helo=guido.klop.ws) by smtp-out1.tiscali.nl with smtp (Tiscali http://www.tiscali.nl) id 1I7rrI-0005QR-RF for ; Mon, 09 Jul 2007 13:56:53 +0200 Received: (qmail 8973 invoked from network); 9 Jul 2007 11:56:52 -0000 Received: from localhost.thuis.klop.ws (HELO guido.klop.ws) (127.0.0.1) by localhost.thuis.klop.ws with SMTP; 9 Jul 2007 11:56:52 -0000 Date: Mon, 09 Jul 2007 13:56:50 +0200 To: freebsd-java@freebsd.org From: "Ronald Klop" Content-Type: text/plain; format=flowed; delsp=yes; charset=us-ascii MIME-Version: 1.0 Content-Transfer-Encoding: Quoted-Printable Message-ID: User-Agent: Opera Mail/9.21 (FreeBSD) Subject: commons-daemon port and LD_LIBRARY_PATH X-BeenThere: freebsd-java@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Porting Java to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 09 Jul 2007 11:56:54 -0000 Hello, As posted in another thread I made a simple port of the jakarta project = = commons-daemon. Commons-daemon consists of an executable 'jsvc' which links java and = starts the application use an API defined in commons-daemon.jar. Everything compiles and runs almost. I only have one problem. It exists with this error. 'Error occurred during initialization of VM Unable to load native library: Shared object "libjvm.so" not found, = required by "libjava.so"' The jsvc programma forks itself and the child gives this error. If I first set = LD_LIBRARY_PATH=3D/usr/local/diablo-jdk1.5.0/jre/lib/i386:/usr/local/dia= ble-jdk1.5.0/jre/lib/i386/client = and then start jsvc everythings works ok. How can I make the jsvc-child find the same libs as its parent. Truss = shows that the parent finds the libs without LD_LIBRARY_PATH set. Cheers, Ronald. -- = Ronald Klop Amsterdam, The Netherlands