httpd-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Jeff Trawick <>
Subject Re: cvs commit: apache-2.0/src/modules/mpm/prefork prefork.c
Date Fri, 09 Jun 2000 16:55:35 GMT
> Date: Fri, 9 Jun 2000 11:31:57 -0400 (EDT)
> From: David Williams <>
> On Fri, 9 Jun 2000, Jeff Trawick wrote:
> > Telling APR which lock to use via hints.m4 is something somebody needs
> > to implement before long, but the TPF and SGI issue I meant to allude
> > to here is that APR has no implementation of the most efficient locks
> > on those platforms. prefork did, but not after this commit.  I won't
> > lose any sleep over it (TPF and SGI can if they so choose), but I
> > thought I would mention it.
> Is that something that could be added to mpm/prefork/config.m4?  Or is
> there no way for configure to easily check the platform by a "uname"
> type call. For alpha 3, I needed to add this to config.m4:
>         [Define this if File Control serialization will be used.])
> for the accept_mutex_on() to work properly on unix.
> thanks,
> -david

You shouldn't need anything like that in config.m4 anymore (well, once
you get the current level of code).

prefork.c is now fixed so that it will always get an accept mutex for
the multiple listen case and unless SINGLE_LISTEN_NO_SERIALIZED_ACCEPT
is defined it will get an accept mutex for the single listen case.
prefork.c no longer decides which syscalls to use for the accept
mutex; that is deferred to APR.

If you want to tell APR to use SysV sems instead of fcntl() locks
(just an example):  there is no clean way to do that yet...
Eventually there will be stuff in hints.m4 to choose the best known
mutex primitive for various platforms.

Currently you can play tricks in src/lib/apr/locks/unix/lock.h after
apr_private.h is included and before any #ifdef APR_USE_xyz_SERIALIZE,
but I wouldn't recommend that for general use :) 

Jeff Trawick | | PGP public key at web site:
          Born in Roswell... married an alien...

View raw message