--- ./util/RE.c++.00	2008-08-06 21:41:40.000000000 -0700
+++ ./util/RE.c++	2008-12-09 10:44:55.830000006 -0800
@@ -27,7 +27,7 @@
 /*
  * Regular expression support.
  */
-#include <RE.h>
+#include "RE.h"
 
 RE::RE(const char* pat, int len, int flags)
     : _pattern(pat, len == 0 ? strlen(pat) : len)
--- ./util/Makefile.SYSV5dso.00	2008-12-09 10:44:55.840000003 -0800
+++ ./util/Makefile.SYSV5dso	2008-12-09 10:44:55.830000023 -0800
@@ -0,0 +1,45 @@
+#	$Id: Makefile.SOLARISdso,v 1.3 2006/01/31 19:31:26 faxguy Exp $
+#
+# HylaFAX Facsimile Software
+#
+# Copyright (c) 1990-1996 Sam Leffler
+# Copyright (c) 1991-1996 Silicon Graphics, Inc.
+# HylaFAX is a trademark of Silicon Graphics
+# 
+# Permission to use, copy, modify, distribute, and sell this software and 
+# its documentation for any purpose is hereby granted without fee, provided
+# that (i) the above copyright notices and this permission notice appear in
+# all copies of the software and related documentation, and (ii) the names of
+# Sam Leffler and Silicon Graphics may not be used in any advertising or
+# publicity relating to the software without the specific, prior written
+# permission of Sam Leffler and Silicon Graphics.
+# 
+# THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND, 
+# EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY 
+# WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE.  
+# 
+# IN NO EVENT SHALL SAM LEFFLER OR SILICON GRAPHICS BE LIABLE FOR
+# ANY SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND,
+# OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS,
+# WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF 
+# LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE 
+# OF THIS SOFTWARE.
+#
+
+#
+# DSO-specific rules for the util directory.
+#
+
+libfaxutil.${DSO}: ${OBJECTS}
+	CC ${DSOOPTS} -o libfaxutil.${DSO}.${LIBVERSION} ${OBJECTS}
+	ln -s libfaxutil.${DSO}.${LIBVERSION} libfaxutil.${DSO}
+
+../util/libfaxutil.${DSO}: libfaxutil.${DSO}
+
+installDSO: libfaxutil.${DSO}
+	${PUTCLIENT} -F ${LIBDIR} -m 755 -O libfaxutil.${DSO}.${LIBVERSION}
+	(cd ${LIBDIR}; ln -s libfaxutil.${DSO}.${LIBVERSION} libfaxutil.${DSO})
+
+cleanDSO::
+	-${RM} -f libfaxutil.${DSO}.${LIBVERSION} libfaxutil.${DSO}
+
--- ./faxd/Makefile.SYSV5dso.00	2008-12-09 10:44:55.840000018 -0800
+++ ./faxd/Makefile.SYSV5dso	2008-12-09 10:44:55.840000014 -0800
@@ -0,0 +1,45 @@
+#	$Id: Makefile.SOLARISdso,v 1.3 2006/01/31 19:31:26 faxguy Exp $
+#
+# HylaFAX Facsimile Software
+#
+# Copyright (c) 1990-1996 Sam Leffler
+# Copyright (c) 1991-1996 Silicon Graphics, Inc.
+# HylaFAX is a trademark of Silicon Graphics
+# 
+# Permission to use, copy, modify, distribute, and sell this software and 
+# its documentation for any purpose is hereby granted without fee, provided
+# that (i) the above copyright notices and this permission notice appear in
+# all copies of the software and related documentation, and (ii) the names of
+# Sam Leffler and Silicon Graphics may not be used in any advertising or
+# publicity relating to the software without the specific, prior written
+# permission of Sam Leffler and Silicon Graphics.
+# 
+# THE SOFTWARE IS PROVIDED "AS-IS" AND WITHOUT WARRANTY OF ANY KIND, 
+# EXPRESS, IMPLIED OR OTHERWISE, INCLUDING WITHOUT LIMITATION, ANY 
+# WARRANTY OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE.  
+# 
+# IN NO EVENT SHALL SAM LEFFLER OR SILICON GRAPHICS BE LIABLE FOR
+# ANY SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY KIND,
+# OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS,
+# WHETHER OR NOT ADVISED OF THE POSSIBILITY OF DAMAGE, AND ON ANY THEORY OF 
+# LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE 
+# OF THIS SOFTWARE.
+#
+
+#
+# DSO-specific rules for the faxd directory.
+#
+#LDIRT	+= libfaxserver.a
+
+libfaxserver.${DSO}: ${SERVER_OBJS} ${MODEM_OBJS}
+	CC ${DSOOPTS} -o libfaxserver.${DSO}.${LIBVERSION} \
+	    ${SERVER_OBJS} ${MODEM_OBJS} ${LLDLIBS}
+	ln -s libfaxserver.${DSO}.${LIBVERSION} libfaxserver.${DSO}
+
+installDSO: libfaxserver.${DSO}
+	${PUTSERV} -F ${LIBDIR} -m 755 -O libfaxserver.${DSO}.${LIBVERSION}
+	(cd ${LIBDIR}; ln -s libfaxserver.${DSO}.${LIBVERSION} libfaxserver.${DSO})
+
+cleanDSO::
+	-${RM} -f libfaxserver.${DSO}.${LIBVERSION} libfaxserver.${DSO}
+
--- ./etc/faxsetup.sh.in.00	2008-08-06 21:41:40.000000000 -0700
+++ ./etc/faxsetup.sh.in	2008-12-09 10:44:55.840000048 -0800
@@ -46,7 +46,7 @@
 test -d /usr/bsd  && PATH=$PATH:/usr/bsd		# Silicon Graphics
 test -d /usr/5bin && PATH=/usr/5bin:$PATH:/usr/etc	# Sun and others
 test -d /usr/sbin && PATH=/usr/sbin:$PATH		# 4.4BSD-derived
-test -d /usr/local/bin && PATH=$PATH:/usr/local/bin	# for GNU tools
+test -d /usr/gnu/bin && PATH=$PATH:/usr/gnu/bin		# for GNU tools
 
 AWK=@AWK@			# awk for use below
 CAT=@CAT@			# cat command for use below
@@ -559,7 +559,7 @@
     # Functions required by faxaddmodem.
     #
     case $TARGET in
-    *-sunos*|*-linux*|*-ultrix*|*-hpux*|*-freebsd*|*-netbsd*|*-sysv5SCO_SV6*)
+    *-sunos*|*-linux*|*-ultrix*|*-hpux*|*-freebsd*|*-netbsd*|*-sysv5*)
 	dumpTTYFuncs()
 	{
 	    cat<<'EOF'
@@ -588,7 +588,7 @@
 EOF
 	}
 	;;
-    *-svr4*|*-sysv4*|*-sysv5*|*-solaris*)
+    *-svr4*|*-sysv4*|*-solaris*)
 	dumpTTYFuncs()
 	{
 	    cat<<'EOF'
@@ -1391,36 +1391,36 @@
     #
     # Force bin/ps2fax and bin/pdf2fax to point to the appropriate scripts.
     #
-    Note ""
-    Note "Make $DIR_SPOOL/bin/ps2fax a link to $DIR_SPOOL/bin/ps2fax.$PS."
-    Note ""
-    $RM bin/ps2fax
-    $RM bin/pdf2fax
-    if [ -n "$LN_S" ]; then
-	$LN $LN_S ps2fax.$PS bin/ps2fax;
-	if [ $PS = gs ]; then
-	    Note ""
-	    Note "Make $DIR_SPOOL/bin/pdf2fax a link to $DIR_SPOOL/bin/pdf2fax.$PS."
-	    Note ""
-	    $LN $LN_S pdf2fax.$PS bin/pdf2fax;
-	else
-	    Note ""
-	    Note "Server-side PDF conversion is not supported on this system."
-	    Note ""
-	fi
-    else
-	$LN bin/ps2fax.$PS bin/ps2fax;
-	if [ $PS = gs ]; then
-	    Note ""
-	    Note "Make $DIR_SPOOL/bin/pdf2fax a link to $DIR_SPOOL/bin/pdf2fax.$PS."
-	    Note ""
-	    $LN bin/pdf2fax.$PS bin/pdf2fax;
-	else
-	    Note ""
-	    Note "Server-side PDF conversion is not supported on this system."
-	    Note ""
-	fi
-    fi
+    #Note ""
+    #Note "Make $DIR_SPOOL/bin/ps2fax a link to $DIR_SPOOL/bin/ps2fax.$PS."
+    #Note ""
+    #$RM bin/ps2fax
+    #$RM bin/pdf2fax
+    #if [ -n "$LN_S" ]; then
+#	$LN $LN_S ps2fax.$PS bin/ps2fax;
+#	if [ $PS = gs ]; then
+#	    Note ""
+#	    Note "Make $DIR_SPOOL/bin/pdf2fax a link to $DIR_SPOOL/bin/pdf2fax.$PS."
+#	    Note ""
+#	    $LN $LN_S pdf2fax.$PS bin/pdf2fax;
+#	else
+#	    Note ""
+#	    Note "Server-side PDF conversion is not supported on this system."
+#	    Note ""
+#	fi
+#    else
+#	$LN bin/ps2fax.$PS bin/ps2fax;
+#	if [ $PS = gs ]; then
+#	    Note ""
+#	    Note "Make $DIR_SPOOL/bin/pdf2fax a link to $DIR_SPOOL/bin/pdf2fax.$PS."
+#	    Note ""
+#	    $LN bin/pdf2fax.$PS bin/pdf2fax;
+#	else
+#	    Note ""
+#	    Note "Server-side PDF conversion is not supported on this system."
+#	    Note ""
+#	fi
+#    fi
 fi
 
 #
--- ./etc/hylafax.in.00	2008-08-06 21:41:40.000000000 -0700
+++ ./etc/hylafax.in	2008-12-09 10:44:55.840000073 -0800
@@ -42,6 +42,13 @@
 # TARGET:	@TARGET@
 #
 
+CAT=hylafax.cat
+SCRIPTDIR="/etc/init.d"
+SCRIPT="hylafax"
+HYLAFAX_LABEL="hylafax"
+STOPNUM="K05"
+STARTNUM="S80"
+
 #
 # fax server control
 #
@@ -178,6 +185,49 @@
     killall -15 hfaxd
 }
 
+#############################################################################
+#
+# hylafax_enable
+#
+# add a link to this script into the /etc/rc2.d directory, then start
+# the server
+#
+#############################################################################
+hylafax_enable() {
+  # create the /etc/rc2.d startup file
+  if [ -f /etc/rc2.d/$STARTNUM$SCRIPT ]; then
+    # file already exists
+    test -z "$ISL" && dspmsg $CAT 15 "%s is already enabled.\n" $HYLAFAX_LABEL
+  else
+    # link in the file
+    test -z "$ISL" && dspmsg $CAT 16 "Enabling %s ... " $HYLAFAX_LABEL
+    ln $SCRIPTDIR/$SCRIPT /etc/rc2.d/$STARTNUM$SCRIPT
+    ln $SCRIPTDIR/$SCRIPT /etc/rc0.d/$STOPNUM$SCRIPT
+    test -z "$ISL" && dspmsg $CAT 17 "done.\n"
+  fi
+}
+
+#############################################################################
+#
+# hylafax_disable
+#
+# remove any links to this script in /etc/rc2.d
+#
+#############################################################################
+hylafax_disable() {
+  # remove the /etc/rc2.d startup file
+  if [ -f /etc/rc2.d/$STARTNUM$SCRIPT ]; then
+    # unlink the file
+    test -z "$ISL" && dspmsg $CAT 18 "Disabling %s ... " $HYLAFAX_LABEL
+    rm -f /etc/rc2.d/$STARTNUM$SCRIPT
+    rm -f /etc/rc0.d/$STOPNUM$SCRIPT
+    test -z "$ISL" && dspmsg $CAT 19 "done.\n"
+  else
+    # file does not exist
+    test -z "$ISL" && dspmsg $CAT 20 "%s is already disabled.\n" $HYLAFAX_LABEL
+  fi
+}
+
 case $1 in
 'start')
 	do_start
@@ -190,6 +240,12 @@
 	sleep 2 #wait some time...
 	do_start
 	;;
+'enable')
+	hylafax_enable
+	;;
+'disable')
+	hylafax_disable
+	;;
 'start_msg')
 	$ECHO "Starting HylaFAX Servers."
 	;;
@@ -197,6 +253,6 @@
 	$ECHO "Stopping HylaFAX Servers."
 	;;
 *)
-	$ECHO "usage: hylafax {start|stop|restart|start_msg|stop_msg}"
+	$ECHO "usage: hylafax {start|stop|enable|disable|restart|start_msg|stop_msg}"
 	;;
 esac
--- ./etc/Makefile.in.00	2008-08-06 21:41:40.000000000 -0700
+++ ./etc/Makefile.in	2008-12-09 10:44:55.840000091 -0800
@@ -118,18 +118,6 @@
 installSysVInit: hylafax
 	if [ "@SYSVINIT@" = yes ]; then \
 	    ${PUTSERVER} -root ${INSTALLROOT} -F ${DIR_SYSVINIT} -m 755 -O hylafax; \
-	    echo "checking ${DIR_SYSVINITSTART} directories"; \
-	    for i in ${DIR_SYSVINITSTART}; do \
-		if test -d ${DIR_SYSVINIT}/$$i; then \
-		    ${PUTSERVER} -root ${INSTALLROOT} -F ${DIR_SYSVINIT}/$$i -lns ../`basename ${DIR_SYSVINIT}`/hylafax ${NAME_SYSVINITSTART}; \
-		fi; \
-	    done; \
-	    echo "checking ${DIR_SYSVINITSTOP} directories"; \
-	    for i in ${DIR_SYSVINITSTOP}; do \
-		if test -d ${DIR_SYSVINIT}/$$i; then \
-		    ${PUTSERVER} -root ${INSTALLROOT} -F ${DIR_SYSVINIT}/$$i -lns ../`basename ${DIR_SYSVINIT}`/hylafax ${NAME_SYSVINITSTOP}; \
-		fi; \
-	    done; \
 	else \
 	    ${PUTSERVER} -root ${INSTALLROOT} -F ${SBIN} -m 755 hylafax; \
 	fi
--- ./Configure-OSR6.00	2008-12-09 10:44:55.850000017 -0800
+++ ./Configure-OSR6	2008-12-09 10:48:15.170000011 -0800
@@ -0,0 +1,30 @@
+#!/bin/sh
+#
+HOST=i586-sco-sysv5
+CFLAGS="-O2 -Kpthread -Kalloca"
+CXXFLAGS="-O2 -Kpthread -Kalloca"
+NM="/usr/ccs/bin/nm -p"
+if [ "$1" = "-g" ]
+then
+  CC="gcc -D_REENTRANT"
+  CXX="g++ -D_REENTRANT"
+  CFLAGS="$CFLAGS -Wall"
+else
+  CC="cc"
+  CXX="CC"
+fi
+PATH=/sbin:/usr/sbin:/usr/bin:/etc:/tcb/bin:/usr/X11R6/bin:/opt/kde/bin:/usr/gnu/bin:/usr/bin/X11:/usr/java/bin
+export CC CXX CFLAGS CXXFLAGS NM PATH
+rm -f mout-configure
+./configure --nointeractive --disable-pam --target=$HOST \
+            --with-DIR_BIN=/usr/bin \
+            --with-DIR_SBIN=/usr/sbin \
+            --with-DIR_LIBEXEC=/usr/sbin \
+            --with-DIR_LIBDATA=/usr/lib/fax \
+            --with-DIR_LIB=/usr/lib \
+            --with-DIR_MAN=/usr/man \
+            --with-LIBTIFF="-ltiff" \
+            --with-TIFFINC="/usr/include" \
+            --with-LIBDB="-ldb" \
+            --with-DBLIBINC=/usr/include \
+            2>&1 | tee mout-configure
--- ./configure.00	2008-08-06 21:41:40.000000000 -0700
+++ ./configure	2008-12-09 10:44:55.850000068 -0800
@@ -1931,7 +1931,7 @@
 	*sysv4.2uw2.1.3)	CONFIG_OPENFIFO=O_RDWR;;	# UnixWare 2.1.3
 	*-sysv5UnixWare*)	CONFIG_OPENFIFO=O_RDWR;;	# UnixWare 7
 	*-sysv5OpenUNIX*)	CONFIG_OPENFIFO=O_RDWR;;	# OpenUNIX 8
-	*-sysv5SCO_SV*)		CONFIG_OPENFIFO=O_RDWR;;	# OpenServer 6
+	*-sysv5*)		CONFIG_OPENFIFO=O_RDWR;;	# OpenServer 6
 	*)		CONFIG_OPENFIFO=O_RDONLY;;
 	esac
     }
@@ -2109,7 +2109,7 @@
 	*-*-sco*)	CONFIG_MAXGID=60000;;
 	*-sysv5UnixWare*)	CONFIG_MAXGID=60000;;	# UnixWare 7
 	*-sysv5OpenUNIX*)	CONFIG_MAXGID=60000;;	# OpenUNIX 8
-	*-sysv5SCO_SV*)		CONFIG_MAXGID=60000;;	# OpenServer 6
+	*-sysv5*)		CONFIG_MAXGID=60000;;	# OpenServer 6
 	*-hpux*)	CONFIG_MAXGID=60000;;
 	*)		CONFIG_MAXGID=60002;;	# default
 	esac
@@ -2667,7 +2667,7 @@
         *-univel-*)	CONFIG_SOCKARGLENTYPE=size_t;;
         *-sysv5UnixWare*)	CONFIG_SOCKARGLENTYPE=size_t;;
         *-sysv5OpenUNIX*)	CONFIG_SOCKARGLENTYPE=size_t;;
-        *-sysv5SCO_SV*)	CONFIG_SOCKARGLENTYPE=size_t;;
+        *-sysv5*)	CONFIG_SOCKARGLENTYPE=size_t;;
 	*-freebsd4*)	CONFIG_SOCKARGLENTYPE=u_int32_t;;
 	*-freebsd5*)	CONFIG_SOCKARGLENTYPE=u_int32_t;;
         *)		CONFIG_SOCKARGLENTYPE=int;;
@@ -3615,6 +3615,48 @@
 	    "t:t.o; \${C++F} ${DSOOPTS} -o t.${DSOSUF} t.o"
 	}
 	;;
+    *-sysv5*)
+	if [ "X${DIR_LIB}" != "X/usr/lib" ]; then
+	    USE_RPATH=' -R${LIBDIR}'
+	else
+	    USE_RPATH=''
+	fi
+	DSOSUF=so
+#	LIBUTIL=''
+	FAXD='${DEPTH}/faxd'
+	LIBFAXSERVER='-L${FAXD} -lfaxserver'
+	# options here are passed to CC, not directly to ld
+	DSOOPTS='-G -Wl,-h,$@'
+	if [ ${ISGCC} = "yes" ] ; then
+	    LLDOPTS='-L${UTIL} -L${FAXD} -R${LIBDIR} -lfaxutil -lstdc++'
+	    GCOPTS="${GCOPTS} -fpic"
+	    GCXXOPTS="${GCXXOPTS} -fpic"
+	else
+	    LLDOPTS='-L${UTIL} -L${FAXD} -R${LIBDIR} -lfaxutil'
+	    GCOPTS="${GCOPTS} -Kpic"
+	    GCXXOPTS="${GCXXOPTS} -Kpic"
+	fi
+	#LLDOPTS='-L${UTIL} -L${FAXD} -R${LIBDIR} -lfaxutil'
+	DSO=SYSV5
+	CheckCCDSO()
+	{
+	$RM t.c t.o t.${DSOSUF}
+	echo 'int f() { return 0; }'>t.c
+	capture cat t.c
+	runMake t \
+	    't.o:; ${CCF} -c t.c' \
+	    "t: t.o; \${CCF} ${DSOOPTS} -o t.${DSOSUF} t.o"
+	}
+	CheckCXXDSO()
+	{
+	$RM t.c++ t.o t.${DSOSUF}
+	echo 'int f() { return 0; }'>t.c++
+	capture cat t.c++
+	runMake t \
+	    "t.o:; \${C++F} -c \${C++FILE} t.c++${MAKECXXOVERRIDE}" \
+	    "t:t.o; \${C++F} ${DSOOPTS} -o t.${DSOSUF} t.o"
+	}
+	;;
     *)	Note "There is no support for building HylaFAX as DSOs on your system."
 	DSO=no
 	;;
@@ -3819,6 +3861,7 @@
     "
     case $TARGET in
 	*-sunos*)	DIR_SYSVINITS="$DIR_SYSVINITS $DIR_SBIN";;
+	*-sysv5*)	DIR_SYSVINITS="/etc/init.d $DIR_SYSVINITS";;
 	*-hpux*)	DIR_SYSVINITS="/sbin/init.d $DIR_SYSVINITS";;
 	*-dec-osf*)	DIR_SYSVINITS="/sbin/init.d $DIR_SYSVINITS";;
 	*)		;;
@@ -3856,6 +3899,7 @@
 	    *sysv4.2uw2*)	DIR_SYSVINITSTOP="../rc0.d ../rc1.d";;
 	    *-sysv5UnixWare*)	DIR_SYSVINITSTOP="../rc0.d ../rc1.d";;
 	    *-sysv5OpenUNIX*)	DIR_SYSVINITSTOP="../rc0.d ../rc1.d";;
+	    *-sysv5*)	DIR_SYSVINITSTOP="../rc0.d ../rc2.d";;
 	    *)		DIR_SYSVINITSTOP="../rc0.d";;
 	esac
     fi
@@ -3864,7 +3908,7 @@
 	    *-hpux*)		NAME_SYSVINITSTART="S905hylafax" ;;
 	    *-linux*)		NAME_SYSVINITSTART="S97hylafax" ;;
 	    *-*-sco3.2v5*)	NAME_SYSVINITSTART="S90hylafax" ;;
-	    *-sysv5SCO_SV*)	NAME_SYSVINITSTART="S90hylafax" ;;
+	    *-sysv5*)	NAME_SYSVINITSTART="S90hylafax" ;;
 	    *)			NAME_SYSVINITSTART="S80hylafax" ;;
 	esac
     fi
@@ -4057,8 +4101,7 @@
     *-sysv2*)	LOCKS=binary;;
     *-hpux*)	LOCKS=binary;;
     *-sysv4*)	LOCKS="+ascii";;
-    *-sysv5SCO_SV6*)	LOCKS="-ascii";;
-    *-sysv5*)	LOCKS="+ascii";;
+    *-sysv5*)	LOCKS="-ascii";;
     *-solaris*)	LOCKS="+ascii";;
     *-freebsd*)	LOCKS=ascii;;
     *-netbsd*)	LOCKS=ascii;;
@@ -4286,7 +4329,7 @@
     *-linux*)			MANSCHEME=bsd-source-cat;;
     *-ultrix*)			MANSCHEME=bsd-source-cat;;
     *-sunos*)			MANSCHEME=bsd-source-cat-strip;;
-    *-sysv[234]*)		MANSCHEME=sysv-source-cat-strip;;
+    *-sysv[2345]*)		MANSCHEME=sysv-source-cat-strip;;
     *-hpux*)			MANSCHEME=sysv-source-cat-strip;;
     *-solaris*)			MANSCHEME=sysv-source-cat-strip;;
     *-aix*)			MANSCHEME=sysv-source-strip;;
--- ./Install-OSR6.00	2008-12-09 10:44:55.860000009 -0800
+++ ./Install-OSR6	2008-12-09 10:44:55.860000006 -0800
@@ -0,0 +1,23 @@
+#!/bin/sh
+
+MOUT=mout-install
+D=/u/tmp/hylafax
+
+[ -f $MOUT ] && mv $MOUT $MOUT-prev
+[ -d $D ] && rm -rf $D
+mkdir -p $D/etc/init.d
+mkdir -p $D/etc/rc0.d
+mkdir -p $D/etc/rc2.d
+mkdir -p $D/usr/lib
+mkdir -p $D/var/spool
+make install \
+     BIN=$D/usr/bin \
+     LIBDATA=$D/usr/lib/fax \
+     LIBEXEC=$D/usr/sbin \
+     SBIN=$D/usr/sbin \
+     SPOOL=$D/var/spool/hylafax \
+     MAN=$D/usr/man \
+     DIR_SYSVINIT=$D/etc/init.d \
+     LIBDIR=$D/usr/lib 2>&1 | tee $MOUT
+
+rm -f $D/var/spool/hylafax/FIFO
--- ./config.site.00	2008-08-06 21:41:40.000000000 -0700
+++ ./config.site	2008-12-09 10:44:55.860000032 -0800
@@ -75,8 +75,8 @@
 # in forming URLs; they are not directory pathnames
 # in the filesystem.
 #
-#DIR_HTML="/var/httpd/htdocs/hylafax"	# directory for HTML documentation
-#DIR_CGI="/var/httpd/cgi-bin"		# directory for CGI scripts
+DIR_HTML="/usr/lib/apache/htdocs/hylafax" # directory for HTML documentation
+DIR_CGI="/usr/lib/apache/cgi-bin"	# directory for CGI scripts
 #HTMLPATH="/hylafax"			# virtual path to HTML materials
 #CGIPATH="/cgi-bin"			# virtual path to CGI scripts
 
@@ -125,7 +125,7 @@
 # Beware of changing the INSTALL definition; you *must* have an
 # install script that emulates the Silicon Graphics install program!
 #
-#AR="/bin/ar"				# pathname of suitable ar program
+AR="/bin/ar"				# pathname of suitable ar program
 #AROPTS="rc"				# options to ar for creating archive
 #CC="gcc"				# name/pathname of C compiler
 #CXX="gcc"				# name/pathname of C++ compiler
@@ -143,7 +143,7 @@
 #OPTIMIZER="-O"				# optimizer flags
 #PORTFUNCS=""				# non-standard functions to emulate
 #PROTOTYPES="-prototypes"		# C compiler options for checking function prototypes
-#RANLIB=":"				# pathname of suitable ranlib program
+RANLIB=":"				# pathname of suitable ranlib program
 #SHDLIBC="-lc_s"			# shared C library, if not standard
 #SIGHANDLERTYPES='(void(*)(int,...))'	# types to check for signal handler
 #STRIP="/bin/strip"			# strip program used by install.sh
@@ -249,24 +249,24 @@
 # based on whether or not they are capable of processing scripts
 # included in the distribution (e.g AWK and SCRIPT_SH, SED).
 #
-#AWK="/bin/awk"				# pathname of suitable awk program
-#CAT="/bin/cat"				# pathname of suitable cat program
-#CHGRP="/etc/chgrp"			# pathname of suitable chgrp program
-#CHMOD="/etc/chmod"			# pathname of suitable chmod program
-#CHOWN="/etc/chown"			# pathname of suitable chown program
-#CMP="/bin/cmp"				# pathname of suitable cmp program
+AWK="/bin/awk"				# pathname of suitable awk program
+CAT="/bin/cat"				# pathname of suitable cat program
+CHGRP="/bin/chgrp"			# pathname of suitable chgrp program
+CHMOD="/bin/chmod"			# pathname of suitable chmod program
+CHOWN="/bin/chown"			# pathname of suitable chown program
+CMP="/bin/cmp"				# pathname of suitable cmp program
 #COL="/bin/col"				# pathname of suitable col program
 #CP="/bin/cp"				# pathname of suitable cp program
-#ECHO="/bin/echo"			# pathname of suitable echo program
-#GREP="/bin/grep"			# pathname of suitable grep program
+ECHO="/bin/echo"			# pathname of suitable echo program
+GREP="/bin/grep"			# pathname of suitable grep program
 #LN="/bin/ln"				# pathname of suitable ln program
 #LN_S="-s"				# option to ${LN} to create symlink
 #MAN="/usr/bin/man"			# pathname of suitable man program
-#MKDIR="/bin/mkdir"			# pathname of suitable mkdir program
-#MKFIFO="/bin/mkfifo"			# pathname of suitable mkfifo program
+MKDIR="/bin/mkdir"			# pathname of suitable mkdir program
+MKFIFO="/bin/mkfifo"			# pathname of suitable mkfifo program
 #MV="/bin/mv"				# pathname of suitable mv program
 #MV_F="-f"				# option to ${MV} to force operation
 #RMCMD="/bin/rm"			# pathname of suitable rm program
-#SED="/bin/sed"				# pathname of suitable sed program
+SED="/bin/sed"				# pathname of suitable sed program
 #SCRIPT_SH="/bin/sh"			# pathname of suitable shell
-#SORT="/bin/sort"			# pathname of suitable sort program
+SORT="/bin/sort"			# pathname of suitable sort program
