cvs commit: apachen/src/main conf.h
dgaudet 97/10/24 18:52:46 Modified:src CHANGES Configure src/helpers GuessOS src/main conf.h Log: PORT: AIX now uses USE_FCNTL_SERIALIZED_ACCEPT. PR#849 PORT: i386 AIX does not have memmove. PR#1267 PORT: HPUX now defaults to using Spencer regex. PR#482, 1246 PORT: Some versions of netbsd don't automatically define __NetBSD__. Workaround by defining NETBSD. PR#977 PORT: Unixware 2.x requires -lgen for syslog. PR#1249 PORT: Ultrix appears to not have syslog. PORT: Basic Gemini port (treat it like unixware212). PORT: All SVR4 systems now use NET_SIZE_T = size_t, and use HAVE_SHMGET. Submitted by: various Reviewed by: Dean Gaudet, Jim Jagielski, Martin Kraemer, Brian Behlendorf Revision ChangesPath 1.471 +12 -0 apachen/src/CHANGES Index: CHANGES === RCS file: /export/home/cvs/apachen/src/CHANGES,v retrieving revision 1.470 retrieving revision 1.471 diff -u -r1.470 -r1.471 --- CHANGES 1997/10/22 08:26:50 1.470 +++ CHANGES 1997/10/25 01:52:41 1.471 @@ -1,5 +1,17 @@ Changes with Apache 1.3b3 + *) PORT: AIX now uses USE_FCNTL_SERIALIZED_ACCEPT. PR#849 + PORT: i386 AIX does not have memmove. PR#1267 + PORT: HPUX now defaults to using Spencer regex. PR#482, 1246 + PORT: Some versions of netbsd don't automatically define + __NetBSD__. Workaround by defining NETBSD. PR#977 + PORT: Unixware 2.x requires -lgen for syslog. PR#1249 + PORT: Ultrix appears to not have syslog. + PORT: Basic Gemini port (treat it like unixware212). + PORT: All SVR4 systems now use NET_SIZE_T = size_t, and + use HAVE_SHMGET. + [various] + *) Various improvements in detecting config file errors (missing closing directives for Directory, Files etc. blocks, prohibiting global server settings in VirtualHost blocks, flagging unhandled multiple 1.163 +11 -8 apachen/src/Configure Index: Configure === RCS file: /export/home/cvs/apachen/src/Configure,v retrieving revision 1.162 retrieving revision 1.163 diff -u -r1.162 -r1.163 --- Configure 1997/10/24 19:35:16 1.162 +++ Configure 1997/10/25 01:52:42 1.163 @@ -223,10 +223,12 @@ *-hp-hpux10.*) OS='HP-UX 10' CFLAGS=$CFLAGS -DHPUX10 + DEF_WANTHSREGEX=yes ;; *-hp-hpux*) OS='HP-UX' CFLAGS=$CFLAGS -DHPUX + DEF_WANTHSREGEX=yes ;; *-sgi-irix64) # Note: We'd like to see patches to compile 64-bit, but for now... @@ -304,14 +306,15 @@ DBM_LIB= DB_LIB= ;; -*486-*-freebsd*|*486-*-netbsd*) - OS='FreeBSD/NETBSD on 486' +*-netbsd*) + OS='NetBSD' + CFLAGS=$CFLAGS -DNETBSD LIBS=$LIBS -lcrypt DBM_LIB= DB_LIB= ;; -*-freebsd*|*-netbsd*) - OS='FreeBSD/NetBSD' +*-freebsd*) + OS='FreeBSD' LIBS=$LIBS -lcrypt DBM_LIB= DB_LIB= @@ -398,17 +401,17 @@ DEF_WANTHSREGEX=yes OS='Unixware' CFLAGS=$CFLAGS -DSVR4 -DNO_LINGCLOSE - LIBS=$LIBS -lsocket -lnsl -lcrypt + LIBS=$LIBS -lsocket -lnsl -lcrypt -lgen ;; *-unixware211) OS='Unixware 2.1.1' CFLAGS=$CFLAGS -DUW - LIBS=$LIBS -lsocket -lnsl -lcrypt + LIBS=$LIBS -lsocket -lnsl -lcrypt -lgen ;; *-unixware212) OS='Unixware 2.1.2' CFLAGS=$CFLAGS -DUW - LIBS=$LIBS -lsocket -lnsl -lcrypt + LIBS=$LIBS -lsocket -lnsl -lcrypt -lgen DBM_LIB= ;; maxion-*-sysv4*) @@ -419,7 +422,7 @@ ;; *-sni-sysv4*) OS='SVR4' - CFLAGS=$CFLAGS -DSVR4 -D_XPG_IV -DHAVE_MMAP + CFLAGS=$CFLAGS -DSVR4 -D_XPG_IV DEF_WANTHSREGEX=yes LIBS=$LIBS -lsocket -lnsl -lc ;; 1.32 +5 -0 apachen/src/helpers/GuessOS Index: GuessOS === RCS file: /export/home/cvs/apachen/src/helpers/GuessOS,v retrieving revision 1.31 retrieving revision 1.32 diff -u -r1.31 -r1.32 --- GuessOS 1997/10/02 05:24:58 1.31 +++ GuessOS 1997/10/25 01:52:44 1.32 @@ -178,6 +178,11 @@ echo ${MACHINE}-whatever-sysv4; exit 0 ;; +UnixWare:5:99*:*) + # Gemini, beta release of next rev of unixware + echo ${MACHINE}-whatever-unixware212; exit 0 + ;; + DYNIX/ptx:4*:*) echo ${MACHINE}-whatever-sysv4; exit 0 ;; 1.150 +6 -4 apachen/src/main/conf.h Index: conf.h === RCS file: /export/home/cvs/apachen/src/main/conf.h,v retrieving revision 1.149 retrieving revision 1.150
cvs commit: apachen/src PORTING
dgaudet 97/10/24 22:34:42 Modified:src PORTING Log: typo Revision ChangesPath 1.14 +1 -1 apachen/src/PORTING Index: PORTING === RCS file: /export/home/cvs/apachen/src/PORTING,v retrieving revision 1.13 retrieving revision 1.14 diff -u -r1.13 -r1.14 --- PORTING 1997/09/30 23:24:49 1.13 +++ PORTING 1997/10/25 05:34:41 1.14 @@ -225,7 +225,7 @@ public servers). See htdocs/manual/misc/perf-tuning.html. - USE_PTHREADS_SERIALIZED_ACCEPT: + USE_PTHREAD_SERIALIZED_ACCEPT: Use POSIX mutexes to serialize accept. See htdocs/manual/misc/perf-tuning.html.
cvs commit: apachen/htdocs/manual/misc perf-tuning.html
dgaudet 97/10/24 22:35:44 Modified:htdocs/manual/misc perf-tuning.html Log: typo Revision ChangesPath 1.3 +1 -1 apachen/htdocs/manual/misc/perf-tuning.html Index: perf-tuning.html === RCS file: /export/home/cvs/apachen/htdocs/manual/misc/perf-tuning.html,v retrieving revision 1.2 retrieving revision 1.3 diff -u -r1.2 -r1.3 --- perf-tuning.html 1997/10/24 09:39:17 1.2 +++ perf-tuning.html 1997/10/25 05:35:43 1.3 @@ -368,7 +368,7 @@ webserver with code-DUSE_USLOCK_SERIALIZED_ACCEPT/code on the codeEXTRA_CFLAGS/code. -dtcodeUSE_PTHREADS_SERIALIZED_ACCEPT/code +dtcodeUSE_PTHREAD_SERIALIZED_ACCEPT/code dd(1.3 or later) This method uses POSIX mutexes and should work on any architecture implementing the full POSIX threads specification, however appears to only work on Solaris (2.5 or later). This is the
cvs commit: apachen/src/os/win32 service.c
pcs 97/10/25 09:57:55 Modified:src/os/win32 service.c Log: Make the NT version issue errors if it cannot install or remove itself as a service. Reviewed by: Dean Gaudet, Brian Behlendorf Revision ChangesPath 1.4 +60 -25apachen/src/os/win32/service.c Index: service.c === RCS file: /export/home/cvs/apachen/src/os/win32/service.c,v retrieving revision 1.3 retrieving revision 1.4 diff -u -r1.3 -r1.4 --- service.c 1997/08/13 08:37:35 1.3 +++ service.c 1997/10/25 16:57:54 1.4 @@ -11,6 +11,39 @@ #include multithread.h #include service.h +/* + * ReportWin32Error() - map the last Win32 error onto a string + * + * This function can be called after a Win32 function has returned an error + * status. This function writes an error line to the file pointed to by + * fp (which could be stdout or stderr) consisting of the passed-in prefix + * string, a colon, and the system error text corresponding to the last + * Win32 function error. + * + * If the file pointer argument is NULL, nothing is logged. + */ + +void ReportWin32Error(FILE *fp, char *prefix) { +LPVOID lpMsgBuf; + +if (!fp) return; + +FormatMessage( +FORMAT_MESSAGE_ALLOCATE_BUFFER | FORMAT_MESSAGE_FROM_SYSTEM, +NULL, +GetLastError(), +MAKELANGID(LANG_NEUTRAL, SUBLANG_DEFAULT), // Default language +(LPTSTR) lpMsgBuf, +0, +NULL +); + +fprintf(fp, %s: %s\n, prefix, lpMsgBuf); + +// Free the buffer. +LocalFree( lpMsgBuf ); +} + static struct { @@ -116,8 +149,7 @@ return; } -void -service_set_status(int status) +void service_set_status(int status) { ReportStatusToSCMgr(status, NO_ERROR, 3000); } @@ -166,7 +198,6 @@ } ReportStatusToSCMgr(state, NO_ERROR, 0); - } @@ -219,7 +250,7 @@ TCHAR szPath[512]; -if ( GetModuleFileName( NULL, szPath, 512 ) == 0 ) +if (GetModuleFileName( NULL, szPath, 512 ) == 0) { exit(1); return; @@ -230,8 +261,10 @@ NULL, // database (NULL == default) SC_MANAGER_ALL_ACCESS // access required ); -if ( schSCManager ) -{ + if (!schSCManager) { + ReportWin32Error(stderr, Cannot open service manager); +} +else { schService = CreateService( schSCManager, // SCManager database globdat.name,// name of service @@ -247,12 +280,11 @@ NULL, // LocalSystem account NULL); // no password -if ( schService ) -{ +if (schService) { CloseServiceHandle(schService); } -else -{ +else { +ReportWin32Error(stderr, Cannot create service); } CloseServiceHandle(schSCManager); @@ -273,25 +305,28 @@ NULL, // database (NULL == default) SC_MANAGER_ALL_ACCESS // access required ); -if ( schSCManager ) -{ +if (!schSCManager) { +ReportWin32Error(stderr, Cannot open service manager); +} +else { schService = OpenService(schSCManager, globdat.name, SERVICE_ALL_ACCESS); -/* try to stop the service */ -if(ControlService(schService, SERVICE_CONTROL_STOP, globdat.ssStatus)) -{ -Sleep(1000); -while(QueryServiceStatus(schService, globdat.ssStatus)) -{ -if(globdat.ssStatus.dwCurrentState == SERVICE_STOP_PENDING) -Sleep(1000); -else -break; -} +if (schService == NULL) { +/* Could not open the service */ +ReportWin32Error(stderr, Error accessing service); } +else { +/* try to stop the service */ +if (ControlService(schService, SERVICE_CONTROL_STOP, globdat.ssStatus)) { +Sleep(1000); +while(QueryServiceStatus(schService, globdat.ssStatus)) { +if(globdat.ssStatus.dwCurrentState == SERVICE_STOP_PENDING) +Sleep(1000); +else +break; +} +} -if (schService) -{ // now remove the service DeleteService(schService); CloseServiceHandle(schService);
cvs commit: apachen/conf access.conf-dist-win httpd.conf-dist-win srm.conf-dist-win
ben 97/10/25 12:10:11 Modified:conf access.conf-dist-win httpd.conf-dist-win srm.conf-dist-win Log: Changes for Windows install. Revision ChangesPath 1.3 +1 -1 apachen/conf/access.conf-dist-win Index: access.conf-dist-win === RCS file: /export/home/cvs/apachen/conf/access.conf-dist-win,v retrieving revision 1.2 retrieving revision 1.3 diff -u -r1.2 -r1.3 --- access.conf-dist-win 1997/07/22 22:31:36 1.2 +++ access.conf-dist-win 1997/10/25 19:10:09 1.3 @@ -17,7 +17,7 @@ # This should be changed to whatever you set DocumentRoot to. -Directory /apache/htdocs +Directory @@ServerRoot@@/htdocs # This may also be None, All, or any combination of Indexes, # Includes, FollowSymLinks, ExecCGI, or MultiViews. 1.5 +1 -1 apachen/conf/httpd.conf-dist-win Index: httpd.conf-dist-win === RCS file: /export/home/cvs/apachen/conf/httpd.conf-dist-win,v retrieving revision 1.4 retrieving revision 1.5 diff -u -r1.4 -r1.5 --- httpd.conf-dist-win 1997/07/22 22:33:11 1.4 +++ httpd.conf-dist-win 1997/10/25 19:10:10 1.5 @@ -41,7 +41,7 @@ # ServerRoot: The directory the server's config, error, and log files # are kept in -ServerRoot /apache +ServerRoot @@ServerRoot@@ # BindAddress: You can support virtual hosts with this option. This option # is used to tell the server which IP address to listen to. It can either 1.4 +1 -1 apachen/conf/srm.conf-dist-win Index: srm.conf-dist-win === RCS file: /export/home/cvs/apachen/conf/srm.conf-dist-win,v retrieving revision 1.3 retrieving revision 1.4 diff -u -r1.3 -r1.4 --- srm.conf-dist-win 1997/07/22 22:31:37 1.3 +++ srm.conf-dist-win 1997/10/25 19:10:10 1.4 @@ -16,7 +16,7 @@ # documents. By default, all requests are taken from this directory, but # symbolic links and aliases may be used to point to other locations. -DocumentRoot /apache/htdocs +DocumentRoot @@ServerRoot@@/htdocs # UserDir: The name of the directory which is appended onto a user's home # directory if a ~user request is recieved.
cvs commit: apachen/src/support apachectl httpd.8 suexec.h
sameer 97/10/25 15:35:21 Modified:.README.NT conf httpd.conf-dist-win htdocs/manual install.html invoking.html stopping.html suexec.html htdocs/manual/misc FAQ.html htdocs/manual/mod core.html mod_alias.html src CHANGES src/main httpd.h src/modules/standard mod_cgi.c src/support apachectl httpd.8 suexec.h Log: Set default pathnames -everywhere- to /usr/local/apache Submitted by: Sameer Parekh Reviewed by: Jim, Martin Revision ChangesPath 1.7 +1 -1 apachen/README.NT Index: README.NT === RCS file: /export/home/cvs/apachen/README.NT,v retrieving revision 1.6 retrieving revision 1.7 diff -c -u -r1.6 -r1.7 /usr/bin/diff: conflicting specifications of output style --- README.NT 1997/10/22 13:30:02 1.6 +++ README.NT 1997/10/25 22:35:05 1.7 @@ -55,7 +55,7 @@ Due to the behavior of NT when multiple processes have a socket open for listening, I would recommend that you set the following in httpd.conf -(in the directory /usr/local/etc/httpd/conf): +(in the directory /usr/local/apache/conf): # Start up 3 servers (in case one dies, another can take its place, while # a new one is spawned 1.6 +1 -1 apachen/conf/httpd.conf-dist-win Index: httpd.conf-dist-win === RCS file: /export/home/cvs/apachen/conf/httpd.conf-dist-win,v retrieving revision 1.5 retrieving revision 1.6 diff -c -u -r1.5 -r1.6 /usr/bin/diff: conflicting specifications of output style --- httpd.conf-dist-win 1997/10/25 19:10:10 1.5 +++ httpd.conf-dist-win 1997/10/25 22:35:06 1.6 @@ -135,7 +135,7 @@ # To enable the cache as well, edit and uncomment the following lines: -#CacheRoot /usr/local/etc/httpd/proxy +#CacheRoot /usr/local/apache/proxy #CacheSize 5 #CacheGcInterval 4 #CacheMaxExpire 24 1.15 +1 -1 apachen/htdocs/manual/install.html Index: install.html === RCS file: /export/home/cvs/apachen/htdocs/manual/install.html,v retrieving revision 1.14 retrieving revision 1.15 diff -c -u -r1.14 -r1.15 /usr/bin/diff: conflicting specifications of output style --- install.html 1997/08/24 12:55:09 1.14 +++ install.html 1997/10/25 22:35:07 1.15 @@ -164,7 +164,7 @@ To start the server, simply run CODEhttpd/CODE. This will look for CODEhttpd.conf/CODE in the location compiled into the code (by -default CODE/usr/local/etc/httpd/conf/httpd.conf/CODE). If +default CODE/usr/local/apache/conf/httpd.conf/CODE). If this file is somewhere else, you can give the real location with the -f argument. For example: 1.13 +1 -1 apachen/htdocs/manual/invoking.html Index: invoking.html === RCS file: /export/home/cvs/apachen/htdocs/manual/invoking.html,v retrieving revision 1.12 retrieving revision 1.13 diff -c -u -r1.12 -r1.13 /usr/bin/diff: conflicting specifications of output style --- invoking.html 1997/07/06 17:18:54 1.12 +++ invoking.html 1997/10/25 22:35:08 1.13 @@ -30,7 +30,7 @@ ddSet the initial value for the A HREF=mod/core.html#serverrootServerRoot/A variable to emserverroot/em. This can be overridden by the ServerRoot command in the -configuration file. The default is code/usr/local/etc/httpd/code. +configuration file. The default is code/usr/local/apache/code. dtcode-f/code emconfig/em ddExecute the commands in the file emconfig/em on startup. If 1.9 +2 -2 apachen/htdocs/manual/stopping.html Index: stopping.html === RCS file: /export/home/cvs/apachen/htdocs/manual/stopping.html,v retrieving revision 1.8 retrieving revision 1.9 diff -c -u -r1.8 -r1.9 /usr/bin/diff: conflicting specifications of output style --- stopping.html 1997/06/04 11:07:51 1.8 +++ stopping.html 1997/10/25 22:35:08 1.9 @@ -25,13 +25,13 @@ pTo send a signal to the parent you should issue a command such as: blockquotepre -kill -TERM `cat /usr/local/etc/httpd/logs/httpd.pid` +kill -TERM `cat /usr/local/apache/logs/httpd.pid` /pre/blockquote You can read about its progress by issuing: blockquotepre -tail -f /usr/local/etc/httpd/logs/error_log +tail -f /usr/local/apache/logs/error_log /pre/blockquote Modify those examples to match your 1.14 +6 -6 apachen/htdocs/manual/suexec.html Index: suexec.html