httpd-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Dean Gaudet <dgau...@arctic.org>
Subject [PATCH] clean up Linux errors due to inconsistent linux platforms
Date Mon, 14 Apr 1997 02:48:13 GMT
The change I introduced in 1.2b8 to deal with users who run multiple
apaches on linux without changing ScoreBoardFile has proven to be a pain
in the butt because of how inconsistent linux can be from machine to
machine (libraries and kernel options).  See PR#336 and PR#340 for
example.

Given that we now document the ScoreBoardFile properly, I'm retracting
this change in the interests of just getting 1.2 done.  But several people
are happy with the performance increase of HAVE_SHMGET (and eliminating
the fcntl accept locking) so I'd like to change it to a compile time
option documented in Configuration.tmpl. 

BTW, this doesn't close PR#336 since PR#336 also has 64-bit issues that
are probably the same as those given in PR#344. 

Dean

Index: CHANGES
===================================================================
RCS file: /export/home/cvs/apache/src/CHANGES,v
retrieving revision 1.231
diff -c -3 -r1.231 CHANGES
*** CHANGES	1997/04/14 01:09:12	1.231
--- CHANGES	1997/04/14 02:43:36
***************
*** 1,5 ****
--- 1,11 ----
  Changes with Apache 1.2
  
+   *) Back out the HAVE_SHMGET change for Linux because it's too late in
+      the beta cycle to deal cleanly with compilation problems on the
+      myriad of linux systems out there.  Linux users should see
+      Configuration.tmpl about defining "Rule LINUX_TWEAK=yes".
+      [Dean Gaudet] PR#336, PR#340
+ 
    *) Redirect did not preserve ?query_strings when present in the client's
       request.  [Dean Gaudet]
  
Index: Configuration.tmpl
===================================================================
RCS file: /export/home/cvs/apache/src/Configuration.tmpl,v
retrieving revision 1.56
diff -c -3 -r1.56 Configuration.tmpl
*** Configuration.tmpl	1997/04/12 12:14:53	1.56
--- Configuration.tmpl	1997/04/14 02:43:36
***************
*** 57,63 ****
  # functions. The format is: Rule RULE=value
  #
  # At present, only the following RULES are known: WANTHSREGEX, SOCKS4,
! # STATUS and IRIXNIS.
  #
  # For all Rules, if set to "yes", then Configure knows we want that
  # capability and does what is required to add it in. If set to "default"
--- 57,63 ----
  # functions. The format is: Rule RULE=value
  #
  # At present, only the following RULES are known: WANTHSREGEX, SOCKS4,
! # STATUS, IRIXNIS, and LINUX_TWEAK.
  #
  # For all Rules, if set to "yes", then Configure knows we want that
  # capability and does what is required to add it in. If set to "default"
***************
*** 80,89 ****
--- 80,97 ----
  #  SGI IRIX. If you are, and you are using NIS, you should set this
  #  to 'yes'
  #
+ # LINUX_TWEAK:
+ #  Only takes effect if Configure determines that you are running a Linux
+ #  system.  This enables two optimizations that work well on i386 linux 2.0
+ #  or later systems.  They aren't enabled by default because of kernel and
+ #  library problems with various versions of linux.  We'd rather release
+ #  something known stable and let you choose the optimizations yourself.
+ #
  
  Rule STATUS=yes
  Rule SOCKS4=no
  Rule IRIXNIS=no
+ Rule LINUX_TWEAK=no
  
  # The following rules should be set automatically by Configure. However, if
  # they are not set by Configure (because we don't know the correct value for
Index: Configure
===================================================================
RCS file: /export/home/cvs/apache/src/Configure,v
retrieving revision 1.90
diff -c -3 -r1.90 Configure
*** Configure	1997/04/13 20:54:34	1.90
--- Configure	1997/04/14 02:43:36
***************
*** 133,138 ****
--- 133,139 ----
  RULE_STATUS=`./helpers/CutRule STATUS $file`
  RULE_SOCKS4=`./helpers/CutRule SOCKS4 $file`
  RULE_IRIXNIS=`./helpers/CutRule IRIXNIS $file`
+ RULE_LINUX_TWEAK=`./helpers/CutRule LINUX_TWEAK $file`
  
  #
  # Now we determine the OS/Platform automagically, thanks to
***************
*** 262,267 ****
--- 263,271 ----
  	DEF_WANTHSREGEX=yes
  	OS='Linux'
  	CFLAGS="$CFLAGS -DLINUX"
+ 	if [ "$RULE_LINUX_TWEAK" = "yes" ]; then
+ 	    CFLAGS="$CFLAGS -DLINUX_TWEAK"
+ 	fi
  	;;
      *-lynx-lynxos*)
  	OS='LynxOS'
Index: conf.h
===================================================================
RCS file: /export/home/cvs/apache/src/conf.h,v
retrieving revision 1.92
diff -c -3 -r1.92 conf.h
*** conf.h	1997/04/09 01:40:51	1.92
--- conf.h	1997/04/14 02:43:37
***************
*** 253,265 ****
  #define NO_USE_SIGACTION
  
  #elif defined(LINUX)
  #undef HAVE_GMTOFF
  #undef NO_KILLPG
  #undef NO_SETSID
  #undef NEED_STRDUP
- #define HAVE_SHMGET
  #define JMP_BUF sigjmp_buf
- #define USE_FCNTL_SERIALIZED_ACCEPT
  #include <sys/time.h>     
  
  #elif defined(SCO)
--- 253,277 ----
  #define NO_USE_SIGACTION
  
  #elif defined(LINUX)
+ #ifndef LINUX_TWEAK
+ /* the old "stable" way ... it's unfortunate that by doing this we'll incur
+  * bug reports from linux users that run multiple Apaches without setting
+  * a different ScoreBoardFile for each of them.
+  */
+ /* #define HAVE_SHMGET */
+ #define USE_FCNTL_SERIALIZED_ACCEPT
+ #else
+ /* this stuff works under 2.0 on i386, but we've had bug reports of it
+  * causing compile-time problems on 1.x systems, and on 2.x alphas.
+  */
+ #define HAVE_SHMGET
+ /* #define USE_FCNTL_SERIALIZED_ACCEPT */
+ #endif
  #undef HAVE_GMTOFF
  #undef NO_KILLPG
  #undef NO_SETSID
  #undef NEED_STRDUP
  #define JMP_BUF sigjmp_buf
  #include <sys/time.h>     
  
  #elif defined(SCO)


Mime
View raw message