Newsgroups: comp.infosystems.www.misc,comp.sys.apollo,boeing.comp.www From: vds7789@aw101.iasl.ca.boeing.com (Vincent D. Skahan) Subject: patches for NCSA httpd v1.3 on Apollo Domain/OS Date: Wed, 13 Jul 1994 19:54:39 GMT The following couple of small patches are needed to httpd-1.3 to get it to compile and run properly on Apollo Domain/OS: - o/s version 10.4.0.11 - system booted in 'BSD' mode - cc version 6.9 After patching, the access log properly reports the time offset from GMT.... -- ----------- Vince Skahan ------ vds7789@aw101.iasl.ca.boeing.com ----------- ------------------------------ cut here -------------------------------------- *** httpd.h.orig Sat May 7 19:47:12 1994 --- httpd.h Wed Jul 13 09:16:36 1994 *************** *** 163,169 **** #include ! #if !defined(NEXT) && !defined(CONVEXOS) #include #define DIR_TYPE dirent #else --- 163,169 ---- #include ! #if !defined(NEXT) && !defined(CONVEXOS) && !defined(APOLLO) #include #define DIR_TYPE dirent #else *** util.c.orig Wed Jul 13 09:17:55 1994 --- util.c Wed Jul 13 12:28:36 1994 *************** *** 8,13 **** --- 8,17 ---- #include "httpd.h" + #if defined(APOLLO) + #include + #endif + char *get_time() { time_t t; char *time_string; *************** *** 38,55 **** time_t tt; struct tm *t; tt = time(NULL); t = localtime(&tt); #if defined(BSD) && !defined(AUX) && !defined(APOLLO) *tz = t->tm_gmtoff; #else ! *tz = - timezone; if(t->tm_isdst) *tz += 3600; #endif return t; } - static char *months[] = { "Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec" --- 42,68 ---- time_t tt; struct tm *t; + #if defined(APOLLO) + struct timeval tp; /* see gettimeofday(2) */ + struct timezone tzp; + #endif + tt = time(NULL); t = localtime(&tt); #if defined(BSD) && !defined(AUX) && !defined(APOLLO) *tz = t->tm_gmtoff; #else ! #if defined(APOLLO) ! gettimeofday(&tp,&tzp); ! *tz = (60 * tzp.tz_minuteswest); ! #else ! *tz = - timezone; ! #endif if(t->tm_isdst) *tz += 3600; #endif return t; } static char *months[] = { "Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec" ------------------------------ cut here -------------------------------------- -- ----------- Vince Skahan ------ vds7789@aw101.iasl.ca.boeing.com -----------