httpd-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Stipe Tolj <t...@wapme-systems.de>
Subject [PATCH] 1.3: further Cygwin platform support
Date Wed, 02 Jan 2002 11:42:01 GMT
I have added a couple of changes to the Cygwin 1.x platform support
for the 1.3 branch. First of all this diff is against a recent cvs
tree. The patch applies cleanly to the current cvs tree.

What's new:

  * Supports now --enable-shared=max option for configure, which is
also used in src/helpers/binbuild.sh for the binary distribution. This
solves especially the mod_proxy compilation problem we had previosly.

  * Cygwin now has an additional configure rule CYGWIN_WINSOCK, which
enables to use Win32 native calls for the socket calls instead of
using POSIX.1 wrappers by the Cygwin emulation layer itself. This is
an performance gain of about 5-10%. Therefore we had to add a couple
of define statements in src/main/buff.c.

  * For accept mutexes we used previously fctnl, which seems to have a
cerious problem when using more then one Listen directive in
httpd.conf. Apache starts and serves on any port specified by Listen,
but does not shut down. Even using the Win32 task manager to kill the
parent httpd process did not suceed. We now use pthread as default
accept mutex mechanism, which works without any known problems.

  * Added #define wrapper for the timeout signal too, that is
different for Cygwin that for other Unixes to be more drastic on this
platform. We still encounter Keep-Alive hanging childs that do not go
away in the timeout limit. This seems to be a Cygwin OS layer problem,
still investigating.


The patch has been created with impact for other platforms in mind. So
there are no changes in behaviour for other OSs.

Here are the changes in the current 1.3 cvs tree:

  * src/Configuration.tmpl: added Rule CYGWIN_WINSOCK for Win32 native
socket support.
  * src/Configure: added checking for RULE_CYGWIN_WINSOCK in the
Cygwin case block. Changed OS_MODULE_INCLUDE to use the full
(relative) path, so we can find the additional Makefile in other
source directories too (i.e proxy).
  * src/helpers/binbuild.sh: Added pre-defined MAKERUN statement
(suggested by Martin) to make env safe. Cygwin needs to re-run "make"
due to the fact that linking shared modules requires to have the
shared core DLL present, which is in fact linked at the end.
  * src/helpers/install.sh: add .exe extension for executables on
Cygwin. Martin, this should be a satisfying solution and should work
for any OS (if any would use the script and .exe extensions)?!
  * src/include/ap_config.h: changed default to
USE_PTHREAD_SERIALIZED_ACCEPT.
  * src/main/buff.c: added #defines to include native Win32 socket
calls if CYGWIN_WINSOCK rule is used.
  * src/main/http_main.c: exluded pthread_mutexattr_setpshared() call
for Cygwin, which seems to have OS specific problems. Added aditional
#defines for CYGWIN_WINSOCK. Added wrapper #define SIG_TIMEOUT_KILL to
handle which signal is used for timeout shutdowns of the childs.
  * src/modules/proxy/Makefile.tmpl: the libproxy.dll Makefile rule
has been hard-coded for OS/2, which is not a good idea, Cygwin
produces also a libproxy.dll version, but with other tools, so we have
to introduce an if statement here to see on which OS we are.
  * src/modules/standard/Makefile.Cygwin: added an "empty" rule to
satisfy OS/2 specific dependancies. This won't hurt the build process.
Removing the shared core import library if existing to update
everything inside and use a dummy file to indicate if the re-run
warning has to be displayed. It should be displayed only once, in
order to not annoy the user.
  * src/os/cygwin/os.h: added necessary declarations for the
CYGWIN_WINSOCK rule.


Can someone, maybe Martin and Lars review the code and commit to cvs,
please?!


Stipe

tolj@wapme-systems.de
-------------------------------------------------------------------
Wapme Systems AG

Münsterstr. 248
40470 Düsseldorf

Tel: +49-211-74845-0
Fax: +49-211-74845-299

E-Mail: info@wapme-systems.de
Internet: http://www.wapme-systems.de
-------------------------------------------------------------------
wapme.net - wherever you are
Mime
View raw message