Hi Daniel!

Thanks a lot for your "howto" :)

IT WORKED !!!!!!

My system hast the following configuration:
AIX 4.3.3
Apache 2.0.40
Tomcat 4.0.4 (also the connector, mod_jk)
gcc 2.95.3
libtool 1.42
autoconf 2.53
aclocal 1.4
automake 1.4
make 3.79.1


I did it "exactly" as you described.
(Apache 2 was already made)
1) set CATALINE_HOME, JAVA_HOME
2) cd jakarta-tomcat-connectors-4.0.4-src/jk/native
3) ./buildconf.sh
4) ./configure --with-apxs=/www/apache2/bin/apxs
5) cd common
6) make
7) cd ../apache-2.0

and here I entered the changed libtool-commands:

8) /bin/sh /www/apache2/build/libtool --silent --mode=compile gcc \
-g -O2 -mthreads -DNO_DBM_REWRITEMAP    -U__STR__ -D_USE_IRS -D_THREAD_SAFE
\
-DAP_HAVE_DESIGNATED_INITIALIZER -DUSE_APACHE_MD5 -D_REENTRANT \
-I/www/apache2/include -I../common -prefer-pic -c mod_jk.c && touch
mod_jk.slo

9) /bin/sh /www/apache2/build/libtool --silent --mode=link gcc -g \
-O2 -mthreads -DNO_DBM_REWRITEMAP -U__STR__ -D_USE_IRS -D_THREAD_SAFE \
-DAP_HAVE_DESIGNATED_INITIALIZER -DUSE_APACHE_MD5 -D_REENTRANT \
-I/apps/usr/local/apache2/include \
-export-dynamic -Wl,-brtl -Wl,-brtl -o mod_jk.la -rpath \
/www/apache2/modules -module -avoid-version  mod_jk.lo \
../common/jk_ajp12_worker.lo ../common/jk_connect.lo \
../common/jk_msg_buff.lo ../common/jk_util.lo ../common/jk_ajp13.lo \
../common/jk_pool.lo ../common/jk_worker.lo ../common/jk_ajp13_worker.lo \
../common/jk_lb_worker.lo ../common/jk_sockbuf.lo ../common/jk_map.lo \
../common/jk_uri_worker_map.lo ../common/jk_ajp14.lo \
../common/jk_ajp14_worker.lo ../common/jk_md5.lo \
../common/jk_ajp_common.lo ../common/jk_context.lo

I needed the change the -pthread into -mthreads (I think because auf gcc
2.95.3) and
I added two more -D options which my configure-script wrote into the orig.
apache-2.0/Makefile.

Your last point - the libtool --install - worked, but didn't the result
expected. So I
overjumped that point and copied the mod_jk.so manually.

10) cp apache-2.0/.libs/libmod_jk.so.0.0.0 /www/apache2/modules/mod_jk.so

I also use the same mod_jk.conf and workers.properties as in Apache 1.3 and
it works fine!
I will also send my binary mod_jk.so to John in order to get the collection
more complete :)
Perhaps I'll manage to build mod_jk2 und mod_webapp also.

Have a nice day/night

Johannes




-----Daniel Rinehart <[EMAIL PROTECTED]> schrieb: -----

An: Tomcat Users List <[EMAIL PROTECTED]>
Von: Daniel Rinehart <[EMAIL PROTECTED]>
Datum: 10.09.2002 10:03PM
Thema: RE: AIX Connector Woes (success)

> Excellent.  Let us know, perhaps the hacking you did would work for other
> platforms, as well.  I've had fairly significant grief building the
> connectors from 4.1.10 source on RedHat 7.2, which is a little surprising
to
> me.  If it's hard on Linux, it must be a royal PITA on other platforms,
> though Detlev Beutner already has Windows-DLL versions of 4.1.10
available,
> so maybe I am missing something.


Below is a condensed version of what I did to compile a valid
libmod_jk.so for Apache 2.0.40/Tomcat 4.1.10 on AIX 5.1. At this point I
can't make any guarantees that this will work for anyone else, but
hopefully it will. I'm also 100% positive that this can be made easier and
more automated, but I don't currently pose the time to start hacking the
autoconf scripts.
My build environment is setup as follows, with GNU binaries in my
path before OS specific ones:

tar 1.13.25
libtoolize 1.4d
aclocal 1.6.2
automake 1.6.2
autoconf 2.53
make 3.79.1
gcc 3.2

Additionally I have the following environment variables set:

CATALINA_HOME=/apps/jakarta-tomcat-4.1.9
JAVA_HOME=/usr/java130/

Apache 2.0.40 was built and installed into /apps/usr/local/apache2
with the following options. I don't know if this will matter, but since I
use the libtool generated by Apache instead of the one created by mod_jk,
I'm including it for completeness (long lines wrapped):

./configure --prefix=/apps/usr/local/apache2 --enable-mods-shared=all
--enable-cgi --enable-expires --enable-headers --enable-info
--enable-rewrite --enable-so --enable-ssl --disable-dav --disable-dav-fs
--disable-auth-digest --with-mpm=worker

With the above command on my system I needed to hack libaprutil a
little to get it to compile and install but that's a little off topic.

Once Apache was built and installed I ran the following commands
(long lines wrapped):

tar -zxf jakarta-tomcat-connectors-4.1.10-src.tar.gz

cd jakarta-tomcat-connectors-4.1.10-src/jk/native

./buildconf.sh

./configure --with-apxs=/apps/usr/local/apache2/bin/apxs

cd common/

make

cd ../apache-2.0/

/bin/sh /apps/usr/local/apache2/build/libtool --silent --mode=compile gcc
-g -O2 -pthread -DNO_DBM_REWRITEMAP    -U__STR__ -D_USE_IRS -D_THREAD_SAFE
-DAP_HAVE_DESIGNATED_INITIALIZER   -I/apps/usr/local/apache2/include
-I../common -prefer-pic -c mod_jk.c && touch mod_jk.slo

/bin/sh /apps/usr/local/apache2/build/libtool --silent --mode=link gcc -g
-O2 -pthread -DNO_DBM_REWRITEMAP -U__STR__ -D_USE_IRS -D_THREAD_SAFE
-DAP_HAVE_DESIGNATED_INITIALIZER -I/apps/usr/local/apache2/include
-export-dynamic -Wl,-brtl -Wl,-brtl -o mod_jk.la -rpath
/apps/usr/local/apache2/modules -module -avoid-version  mod_jk.lo
../common/jk_ajp12_worker.lo ../common/jk_connect.lo
../common/jk_msg_buff.lo ../common/jk_util.lo ../common/jk_ajp13.lo
./common/jk_pool.lo ../common/jk_worker.lo ../common/jk_ajp13_worker.lo
../common/jk_lb_worker.lo ../common/jk_sockbuf.lo ../common/jk_map.lo
../common/jk_uri_worker_map.lo ../common/jk_ajp14.lo
../common/jk_ajp14_worker.lo ../common/jk_md5.lo
../common/jk_ajp_common.lo ../common/jk_context.lo

/bin/sh /apps/usr/local/apache2/build/libtool --silent --mode=install cp
mod_jk.la /apps/usr/local/apache2/modules/mod_jk.so

This creates a full suite of *jk* files under modules/ which I
cleaned up by hand. Alternatively you can probably just copy the .so
file out of the .libs directory by hand. The final file on my system
looked something like this:

603266 libmod_jk.so*

I suspect that someone else, based on their system, may need
different libtool lines from those above. The way that I "figured" them
out was to steal them from the compilation of mod_log_config. Under the
source tree that I used to compile Apache 2, I did something like this:

cd modules/loggers/
make clean
cd ../..
make | grep libtool

I then grabbed the two output lines from libtool removed all of
the logger specific references, changed libtool to point to the one under
the installed Apache build directory, modified the include directory to
point to the installed Apache include directory, and lastly changed the
files being compiled to the ones that "make -n" spits out under the
/native/apache-2.0/ directory.

I used the same mod_jk.c and workers.properties that I had under
Apache 1.3.26 without any problems. Hope this helps.

-- Daniel R. <[EMAIL PROTECTED]> [http://www.neophi.com/]


--
To unsubscribe, e-mail:   <
mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <
mailto:[EMAIL PROTECTED]>



--
To unsubscribe, e-mail:   <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>

Reply via email to