From owner-freebsd-java Fri Jun 14 21:33:52 2002 Delivered-To: freebsd-java@freebsd.org Received: from attila.stevens-tech.edu (attila.stevens-tech.edu [155.246.14.11]) by hub.freebsd.org (Postfix) with ESMTP id 42C8A37B423 for ; Fri, 14 Jun 2002 21:33:48 -0700 (PDT) Received: from levindustries.com (jlevine-1.u05.stevens-tech.edu [155.246.211.36]) by attila.stevens-tech.edu (SGI-8.9.3/8.9.3/7) with ESMTP id AAA11483 for ; Sat, 15 Jun 2002 00:33:47 -0400 (EDT) Message-ID: <3D0AC36D.C72E688B@levindustries.com> Date: Sat, 15 Jun 2002 00:32:45 -0400 From: Josh Levine X-Mailer: Mozilla 4.77 [en] (Windows NT 5.0; U) X-Accept-Language: en MIME-Version: 1.0 To: freebsd-java@freebsd.org Subject: JAVA+PHP+Apache on FreeBSD - Success! Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Sender: owner-freebsd-java@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.org Searching the archives I noticed people have asked questions about this in the past, so I figured I'd post a few notes on how I got it working... - Build jdk13 with native threads (make -DWITH_NATIVE_THREADS) - Build Apache with POSIX threads (export LDFLAGS="-pthread -lc_r") - Add /usr/local/jdk1.3.1/jre/lib/i386 to ldconfig_paths in /etc/rc.conf (make sure to copy over the existing paths from /etc/defaults/rc.conf) - Build PHP with Java (--with-java=/usr/local/jdk1.3.1) - Rename the java.so file that the PHP build created to libphp_java.so and make sure it is in the extensions directory definie in the php.ini file Contents of the [Java] section of my php.ini: [Java] java.class.path = /usr/local/lib/php/php_java.jar:/usr/local/jdk1.3.1/jre/lib/rt.jar java.home = /usr/local/jdk1.3.1 java.library = /usr/local/jdk1.3.1/jre/lib/i386/classic/libjvm.so java.library.path = /usr/local/lib/php/extensions:/usr/local/jdk1.3.1/jre/lib/i386:/usr/local/jdk1.3.1/jre/lib/i386/native_threads extension=libphp_java.so I hope this helps someone out, Josh Levine To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-java" in the body of the message