Kurt Miller wrote:
I recently created a port of mod_jk-1.2.1 for OpenBSD and needed to make
some minor patches to mod_jk. OpenBSD 3.2 has Apache 1.3.26 configured as
ServerType standalone, to chroot to /var/www and run as user www by default.
This combination requires a few minor patches so that mod_jk will continue
to work after an Apache restart.
I'm fine with the makefile updates but there is a problem with change in
apache-1.3/mod_jk.c since there is no ap_server_strip_chroot call
available on my Linux box.

Is it an OpenBSD specific call ?

If so we'll have to add some #ifdef OPEN_BSD and I'd like to
have others jk commiters opinion. (I allready put too much
#ifdef AS400 ;)

I'll be to use a #ifdef CHROOTED_APACHE :

--- apache-1.3/mod_jk.c.orig Tue Nov 26 12:26:25 2002
+++ apache-1.3/mod_jk.c Mon Dec 9 01:59:18 2002
...

/* we need an absolut path */
conf->worker_file = ap_server_root_relative(cmd->pool,worker_file);
#ifdef CHROOTED_APACHE
ap_server_strip_chroot(conf->worker_file,0);
#endif

if (conf->worker_file == worker_file)
conf->worker_file = ap_pstrdup(cmd->pool,worker_file);

....


/* we need an absolut path */
conf->log_file = ap_server_root_relative(cmd->pool,log_file);
#ifdef CHROOTED_APACHE
ap_server_strip_chroot(conf->log_file,0);
#endif

if ( conf->log_file == log_file)
conf->log_file = ap_pstrdup(cmd->pool,log_file);

....

@@ -1742,7 +1746,7 @@ static void jk_init(server_rec *s, ap_po
/* Open up log file */
if(conf->log_file && conf->log_level >= 0) {
if(!jk_open_file_logger(&(conf->log), conf->log_file, conf->log_level)) {
#ifdef CHROOTED_APACHE
conf->log = main_log;
#else
conf->log = NULL;
#endif
} else {
main_log = conf->log;
}



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



Reply via email to