From owner-freebsd-java@FreeBSD.ORG Wed Dec 30 05:07:46 2009 Return-Path: Delivered-To: freebsd-java@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 0430B1065694 for ; Wed, 30 Dec 2009 05:07:46 +0000 (UTC) (envelope-from glewis@eyesbeyond.com) Received: from misty.eyesbeyond.com (gerbercreations.com [71.39.140.16]) by mx1.freebsd.org (Postfix) with ESMTP id B45D28FC16 for ; Wed, 30 Dec 2009 05:07:45 +0000 (UTC) Received: from misty.eyesbeyond.com (localhost.eyesbeyond.com [127.0.0.1]) by misty.eyesbeyond.com (8.14.3/8.14.3) with ESMTP id nBU57iQV032448; Tue, 29 Dec 2009 21:07:44 -0800 (PST) (envelope-from glewis@eyesbeyond.com) Received: (from glewis@localhost) by misty.eyesbeyond.com (8.14.3/8.14.3/Submit) id nBU57hCQ032447; Tue, 29 Dec 2009 21:07:43 -0800 (PST) (envelope-from glewis@eyesbeyond.com) X-Authentication-Warning: misty.eyesbeyond.com: glewis set sender to glewis@eyesbeyond.com using -f Date: Tue, 29 Dec 2009 21:07:43 -0800 From: Greg Lewis To: Frederic de la Goublaye Message-ID: <20091230050743.GA32339@misty.eyesbeyond.com> References: <32a0facf0912290134s3411e5ccsd803b2bbec9de5b8@mail.gmail.com> <32a0facf0912291314k3c9725fci845435623a8a5e2a@mail.gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <32a0facf0912291314k3c9725fci845435623a8a5e2a@mail.gmail.com> User-Agent: Mutt/1.5.20 (2009-06-14) Cc: freebsd-java@freebsd.org Subject: Re: mod-jk-apache2 make error with apache22 on FreeBSD 8.0-RELEASE 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: Wed, 30 Dec 2009 05:07:46 -0000 G'day Frederic, On Tue, Dec 29, 2009 at 10:14:50PM +0100, Frederic de la Goublaye wrote: > the solution is here: > http://www.freebsd.org/cgi/query-pr.cgi?pr=138370 Thanks for looking into this. The proposed solution is really a hack on top of a hack. It will work for your particular case, but it isn't going to work for everyone. It looks like the problem originates with the output from apxs, a hack to workaround that and people having compiled Apache with options like MySQL natively (like yourself). The mod_jk build runs apxs to find out the link paths it should use. On my machine that looks like this: > apxs -q LDFLAGS -pthread -rpath=/usr/lib /usr/local/lib -L/usr/lib -L/usr/local/lib Which looks odd. At least some of it (e.g. the naked /usr/local/lib entry in the middle of it) looks bogus. On your machine I suspect it looks something like this: -pthread -rpath=/usr/lib -L/usr/local/lib/mysql /usr/local/lib -L/usr/lib -L/usr/local/lib If you look at patch-tomcat-connectors-src:native:configure in the mod_jk port, it tries to fix this, but sloppily, by replacing the first instance of /usr/local/lib in the line with -L/usr/local/lib. In my case that will work. In your case you'll end up with -rpath=/usr/lib -L-L/usr/local/lib/mysql /usr/local/lib -L/usr/lib -L/usr/local/lib after the substitution and the build will fail. It seems like a better patch would be to remove the raw /usr/local/lib, since there is already a -L/usr/local/lib present. That's still somewhat sloppy as it should really be ${LOCALBASE} rather than hardcoded to /usr/local. All that comes with the caveat that its been a long time since I played with Apache very much. > > I cannot install mod_jk-apache2 after the installation of apache22 on > > FreeBSD 8.0 RELEASE > > > > Can you help me ? > > > > # cd /usr/ports/www/apache22/ > > # make > > # make install > > > > It works! > > > > > > # cd /usr/ports/www/mod_jk-apache2/ > > # make > > > ../common/jk_ajp_common.lo ../common/jk_context.lo ../common/jk_url.lo > > ../common/jk_status.lo > > /usr/local/lib: file not recognized: File format not recognized > > gmake[1]: *** [mod_jk.la] Error 1 > > gmake[1]: Leaving directory > > `/usr/ports/www/mod_jk-apache2/work/tomcat-connectors-1.2.28-src/native/apache-2.0' > > gmake: *** [all-recursive] Error 1 > > *** Error code 1 > > > > Stop in /usr/ports/www/mod_jk-apache2. > > > > # > > > > END OF THE COMMAND LINES > > > _______________________________________________ > freebsd-java@freebsd.org mailing list > http://lists.freebsd.org/mailman/listinfo/freebsd-java > To unsubscribe, send any mail to "freebsd-java-unsubscribe@freebsd.org" -- Greg Lewis Email : glewis@eyesbeyond.com Eyes Beyond Web : http://www.eyesbeyond.com Information Technology FreeBSD : glewis@FreeBSD.org