He explains in some pretty good detail why it fails out of the tar-box, so I won't go into it. However, what I will do is give you a line-by-line for how to make it work. I had to fill in a couple gaps after finding out what the problem was. Here's what you need to do.

1. Download and unpack the source of mod_jk (I installed version 1.2.25)

2. Make your way into the source directory (tomcat-connectors-[version]-src/native)

$ cd tomcat-connectors-1.2.25-src/native

3. Edit the apache-2.0/Makefile.apxs.in file with billo's fix. This is the solution that fixes the build. What you need to do is replace these lines:

Eric, you're blog saved my weekend. I was struggling with restoring my web development environment after upgrading to Leopard. I use Java/JSP/Apache with a tunnel to our databases on a MacBook Pro. Even our "experts" didn't have a solution for me.

I can't thank you enough. Hey...I saw your other post on Social Networks. It was very insightful. I have been working on a social network for itunes users. www.sonicswap.com....send me email over there to dan at sonicswapDotCom. I would love to get in touch. It is good to hang with web developers who "get it"Best regards,Dan

@Anonymous It sounds like it could be a couple things. The first thing to do is to open /Applications/Utilities/Console.app and see what kind of messages you get when you restart apache. I'm thinking that it could be a couple things.

Looks like you have the module built and in the right place. However, the error your getting is what you get when the module is not built correctly. The instructions above should be good. I've checked them a couple times. Here are some details that might have slipped under the radar

1. Make sure to cd into the "native" directory when you do your configure and make. The build will seem like it goes ok if you're not in the "native" directory, but you get the error you mentioned

2. When editing the the Makefile.apxs.in file, make sure there's a tab at the beginning of the $(APXS) line

All of these details are outlined in the instructions above. So, basically, try starting over and following closely :-) Let me know how it goes.

I have my apache2 built and installed in /usr/local/apache2. After I build the mod_jk, I got the following error starting hpptd:

API module structure 'jk_module' in file /usr/local/apache2/modules/mod_jk.so is garbled - expected signature 41503230 but saw 41503232 - perhaps this is not an Apache module DSO, or was compiled for a different Apache version?

I noticed that the build is using -I/usr/include/apache2 instead -I/usr/local/apache2/include even I had APACHE_HOME setup.