Login | Register
My pages Projects Community openCollabNet

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Catacomb] how to debug HTTPd and Catacomb with gdb



After a little bit of work, I've gotten gdb to debug httpd/catacomb...Here's how:

1) When running Apache's configure, add the flag "--enable-maintainer-mode". (And, of course, make sure you include "--enable-dav=shared" as well.) You'll likely have to do a "make clean" if you're doing this in a source tree you've already built in. Do a "make" and a "make install".

2) In Catacomb's Makefile, add "-g" to the end of the CFLAGS line (line 116) (Might want to add this to the configure script...) Do a "make clean" if necessary and a "make" and "make install".

3) Start up gdb by going to the root of the httpd install target and typing "gdb bin/httpd"

4) Start up a single-process server with "run -X"

5) After waiting a few seconds for all of the shared libraries to bind, you can hit ctrl-C to stop the current process and you can now set breakpoints on functions in the Catacomb module. Use "continue" to start the server back up.

(Might want to add this to the Catacomb documentation?)

I might have a fix for the Content-Type identification that I'll post to the Catacomb mailing list. Then, hopefully, we can figger out how to get PHP to work.