From e61af24a2d4dce4e368b6ef1a0c65559d062bcf7 Mon Sep 17 00:00:00 2001 From: kim Date: Sun, 29 Aug 1999 12:26:19 +0000 Subject: FIX: sendmail is /usr/sbin/sendmail on NetBSD (now notify works). While fixing that, I broke out the huge multi-file patch-aa into separate patch files for each patched file in the distribution, and moved new files into ${FILESDIR} for easier maintenance. --- net/rdist6/Makefile | 8 +- net/rdist6/files/mf.netbsd | 22 +++ net/rdist6/files/os-netbsd.h | 124 ++++++++++++++ net/rdist6/files/patch-sum | 11 +- net/rdist6/patches/patch-aa | 376 +------------------------------------------ net/rdist6/patches/patch-ab | 16 ++ net/rdist6/patches/patch-ac | 13 ++ net/rdist6/patches/patch-ad | 39 +++++ net/rdist6/patches/patch-ae | 16 ++ net/rdist6/patches/patch-af | 26 +++ net/rdist6/patches/patch-ag | 20 +++ net/rdist6/patches/patch-ah | 34 ++++ 12 files changed, 330 insertions(+), 375 deletions(-) create mode 100644 net/rdist6/files/mf.netbsd create mode 100644 net/rdist6/files/os-netbsd.h create mode 100644 net/rdist6/patches/patch-ab create mode 100644 net/rdist6/patches/patch-ac create mode 100644 net/rdist6/patches/patch-ad create mode 100644 net/rdist6/patches/patch-ae create mode 100644 net/rdist6/patches/patch-af create mode 100644 net/rdist6/patches/patch-ag create mode 100644 net/rdist6/patches/patch-ah (limited to 'net/rdist6') diff --git a/net/rdist6/Makefile b/net/rdist6/Makefile index d5965063253..f23363c8d90 100644 --- a/net/rdist6/Makefile +++ b/net/rdist6/Makefile @@ -1,4 +1,4 @@ -# $NetBSD: Makefile,v 1.3 1998/08/20 15:17:18 tsarna Exp $ +# $NetBSD: Makefile,v 1.4 1999/08/29 12:26:19 kim Exp $ # DISTNAME= rdist-6.1.4 @@ -13,6 +13,12 @@ RDIST6_NAME= rdist6 INSTALL_TARGET= install install.man MAKE_ENV+= RDIST6_NAME=${RDIST6_NAME} +pre-patch: + @${CP} \ + ${FILESDIR}/mf.netbsd \ + ${FILESDIR}/os-netbsd.h \ + ${WRKSRC}/config + post-install: @strip ${PREFIX}/bin/${RDIST6_NAME} @strip ${PREFIX}/bin/rdistd diff --git a/net/rdist6/files/mf.netbsd b/net/rdist6/files/mf.netbsd new file mode 100644 index 00000000000..2a1695e5b1d --- /dev/null +++ b/net/rdist6/files/mf.netbsd @@ -0,0 +1,22 @@ +# $NetBSD: mf.netbsd,v 1.1 1999/08/29 12:26:20 kim Exp $ +# +# NetBSD Makefile +# + +# +# Functions that are missing in this OS are contained in the +# files specified in ${MISSINGOBJS}. +# +#MISSINGOBJS = $(O)strerror.o $(O)strcasecmp.o + +# +# System libraries that we need to load. +# +LIB_SYS = -lcompat + +# +# System dependent options for compiling +# +#CFLAGS_OS = + +BIN_DIR = /usr/local/bin diff --git a/net/rdist6/files/os-netbsd.h b/net/rdist6/files/os-netbsd.h new file mode 100644 index 00000000000..83110c7f93b --- /dev/null +++ b/net/rdist6/files/os-netbsd.h @@ -0,0 +1,124 @@ +/* $NetBSD: os-netbsd.h,v 1.1 1999/08/29 12:26:21 kim Exp $ + */ + +/* + * Define the following name for use in #ifdef's. + * The value should be all upper-case with no periods (.). + */ +#if !defined(NETBSD) +#define NETBSD +#endif + +/* + * NOTE: NetBSD uses 64-bit file size semantics, and so you + * must be careful when using varargs-type functions + * like the *printf family when printing elements which + * might be 64-bits (such as stat->st_size from stat.h). + */ + +/* + * Set process args to messages that show up when running ps(1) + * + * Under some OS's, the SETARGS code will cause ": is not an identifier" + * errors for "special" commands. + */ +#define SETARGS + +/* + * Define the type of directory routines your system has. + */ +#define DIR_TYPE DIR_DIRENT + +/* + * Determine what routines we have to get filesystem info. + */ +#define FSI_TYPE FSI_GETFSSTAT + +/* + * Type of non-blocking I/O. + */ +#define NBIO_TYPE NBIO_FCNTL + +/* + * Type of wait() function to use. + */ +#define WAIT_TYPE WAIT_WAIT3 + +/* + * Type of argument passed to wait() (above). + */ +#define WAIT_ARG_TYPE int + +/* + * Select the type of executable file format. + */ +#define EXE_TYPE EXE_AOUT + +/* + * Select the type of statfs() system call (if any). + */ +#define STATFS_TYPE STATFS_BSD + +/* + * Type of arg functions we have. + */ +#define ARG_TYPE ARG_STDARG + +/* + * UID argument type for chown() + */ +typedef uid_t CHOWN_UID_T; + +/* + * GID argument type for chown() + */ +typedef gid_t CHOWN_GID_T; + +/* + * Our types, usually these are uid_t and gid_t. + */ +typedef uid_t UID_T; /* Must be signed */ +typedef gid_t GID_T; /* Must be signed */ + +/* + * Generic pointer, used by memcpy, malloc, etc. Usually char or void. + */ +typedef void POINTER; + +/* + * Type of set file time function available + */ +#define SETFTIME_TYPE SETFTIME_UTIMES + +/* + * Type of set line buffering function available + */ +#define SETBUF_TYPE SETLINEBUF + +/* + * Things we have + */ +#define HAVE_FCHOWN /* Have fchown() */ +#define HAVE_FCHMOD /* Have fchmod() */ +#define HAVE_SELECT /* Have select() */ +#define HAVE_SAVED_IDS /* Have POSIX style saved [ug]id's */ +#define POSIX_SIGNALS /* Have POSIX signals */ + +/* + * Things we need + */ +#define NEED_UNISTD_H /* Need */ + +/* + * Path to the remote shell command. + * Define this only if the pathname is different than + * that which appears in "include/paths.h". + */ +#define _PATH_REMSH "/usr/bin/rsh" + +/* + * Path to the sendmail command. + */ +#ifndef _PATH_SENDMAIL +#define _PATH_SENDMAIL "/usr/sbin/sendmail" +#endif diff --git a/net/rdist6/files/patch-sum b/net/rdist6/files/patch-sum index a34195ce75b..6f1a972a438 100644 --- a/net/rdist6/files/patch-sum +++ b/net/rdist6/files/patch-sum @@ -1,3 +1,10 @@ -$NetBSD: patch-sum,v 1.1 1999/07/09 14:12:27 agc Exp $ +$NetBSD: patch-sum,v 1.2 1999/08/29 12:26:21 kim Exp $ -MD5 (patch-aa) = 2830bf9712392b4cb018107b99daa3f2 +MD5 (patch-aa) = c5e9a5acd315f3715323700e27d7b208 +MD5 (patch-ab) = e21fb981d9e9bb3f1eeebf59b279eb9a +MD5 (patch-ac) = dee3dab4fa644050c6bdeb863ce60cd5 +MD5 (patch-ad) = d70b67f7871d6a276a96be80b8cc9242 +MD5 (patch-ae) = 6adfdfc96017cbd039f7c6e74959529e +MD5 (patch-af) = 6ad7be9db90f998dad85832d60a28acf +MD5 (patch-ag) = 69628c934eec9549ada7c6c0665cc13b +MD5 (patch-ah) = 4995c7a3306861dee58c55dcc2713251 diff --git a/net/rdist6/patches/patch-aa b/net/rdist6/patches/patch-aa index 96440eb234c..83f0176845a 100644 --- a/net/rdist6/patches/patch-aa +++ b/net/rdist6/patches/patch-aa @@ -1,380 +1,12 @@ -$NetBSD: patch-aa,v 1.2 1998/08/07 11:10:50 agc Exp $ +$NetBSD: patch-aa,v 1.3 1999/08/29 12:26:21 kim Exp $ ---- build/os-type 1998/04/24 14:27:16 1.1 -+++ build/os-type 1998/04/24 14:28:04 +--- build/os-type.orig Mon Mar 23 19:01:57 1998 ++++ build/os-type Sun Aug 29 07:52:10 1999 @@ -106,6 +106,7 @@ ;; "linux"*) OS=linux;; "freebsd"*) OS="${osname}${osmajver}";; -+ "netbsd"*) OS="netbsd131";; ++ "netbsd"*) OS="netbsd";; # OpenBSD looks like freebsd2 right now "openbsd"*) OS="freebsd2";; "dgux"*) OS=dgux;; ---- include/defs.h 1998/04/24 14:28:52 1.1 -+++ include/defs.h 1998/04/24 14:29:43 -@@ -403,7 +403,11 @@ - extern void error(char *, ...); - extern void fatalerr(char *, ...); - extern void message(int, char *, ...); -+#if defined(NETBSD) -+extern void setproctitle(const char *fmt, ...); -+#else - extern void setproctitle(char *fmt, ...); -+#endif /* NetBSD */ - #else - extern void debugmsg(); - extern void error(); ---- include/filesys.h 1998/04/24 14:30:29 1.1 -+++ include/filesys.h 1998/04/24 14:30:47 -@@ -111,7 +111,7 @@ - typedef struct statvfs statfs_t; - # define statfs(mp,sb) statvfs(mp,sb) - #else --#if defined(BSD386) || defined(__bsdi__) || defined(FREEBSD) || STATFS_TYPE == STATFS_OSF1 -+#if defined(BSD386) || defined(__bsdi__) || defined(FREEBSD) || defined(NETBSD) || STATFS_TYPE == STATFS_OSF1 - typedef struct statfs statfs_t; - #else - # include ---- src/filesys-os.c 1998/04/24 14:35:12 1.1 -+++ src/filesys-os.c 1998/04/24 14:38:58 -@@ -51,7 +51,9 @@ - - #if FSI_TYPE == FSI_GETFSSTAT - static struct statfs *mnt = NULL; -+#if !defined(NETBSD) - typedef u_long ulong; -+#endif /* !NetBSD */ - #endif /* FSI_GETFSSTAT */ - - #if FSI_TYPE == FSI_MNTCTL -@@ -179,6 +181,16 @@ - if (mnt->f_flags & M_RDONLY) - mntstruct.me_flags |= MEFLAG_READONLY; - #endif -+#if defined(NETBSD) -+ if (strcmp(mnt->f_fstypename, MOUNT_NFS)) { -+ (void) sprintf(remote_dev, "%s", mnt->f_mntfromname); -+ mntstruct.me_path = remote_dev; -+ mntstruct.me_type = METYPE_NFS; -+ } else { -+ mntstruct.me_path = mnt->f_mntonname; -+ mntstruct.me_type = METYPE_OTHER; -+ } -+#else - switch ((ulong)((struct statfs*)mnt)->f_type) { - case MOUNT_NFS: - (void) sprintf(remote_dev, "%s", mnt->f_mntfromname); -@@ -190,6 +202,7 @@ - mntstruct.me_type = METYPE_OTHER; - break; - } -+#endif /* !NetBSD */ - - mnt++; - entries_left--; ---- src/setargs.c 1998/04/24 14:40:02 1.1 -+++ src/setargs.c 1998/04/24 14:41:06 -@@ -130,7 +130,11 @@ - /* - * Stdarg front-end to _setproctitle() - */ -+#if defined(NETBSD) -+extern void setproctitle(const char *fmt, ...) -+#else - extern void setproctitle(char *fmt, ...) -+#endif - { - static char buf[BUFSIZ]; - va_list args; ---- /dev/null Fri Apr 24 09:44:17 1998 -+++ config/mf.netbsd131 Fri Apr 24 15:43:50 1998 -@@ -0,0 +1,56 @@ -+# -+# Copyright (c) 1993 Michael A. Cooper -+# Copyright (c) 1993 Regents of the University of California. -+# All rights reserved. -+# -+# Redistribution and use in source and binary forms, with or without -+# modification, are permitted provided that the following conditions -+# are met: -+# 1. Redistributions of source code must retain the above copyright -+# notice, this list of conditions and the following disclaimer. -+# 2. Redistributions in binary form must reproduce the above copyright -+# notice, this list of conditions and the following disclaimer in the -+# documentation and/or other materials provided with the distribution. -+# 3. All advertising materials mentioning features or use of this software -+# must display the following acknowledgement: -+# This product includes software developed by the University of -+# California, Berkeley and its contributors. -+# 4. Neither the name of the University nor the names of its contributors -+# may be used to endorse or promote products derived from this software -+# without specific prior written permission. -+# -+# THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND -+# ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE -+# IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE -+# ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE -+# FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL -+# DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS -+# OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) -+# HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT -+# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY -+# OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF -+# SUCH DAMAGE. -+# -+# -+ -+# -+# NetBSD 1.3.1 Makefile -+# -+ -+# -+# Functions that are missing in this OS are contained in the -+# files specified in ${MISSINGOBJS}. -+# -+#MISSINGOBJS = $(O)strerror.o $(O)strcasecmp.o -+ -+# -+# System libraries that we need to load. -+# -+LIB_SYS = -lcompat -+ -+# -+# System dependent options for compiling -+# -+#CFLAGS_OS = -+ -+BIN_DIR = /usr/local/bin ---- /dev/null Fri Apr 24 09:44:17 1998 -+++ config/os-netbsd131.h Fri Apr 24 15:55:44 1998 -@@ -0,0 +1,156 @@ -+/* -+ * Copyright (c) 1993 Michael A. Cooper -+ * Copyright (c) 1993 Regents of the University of California. -+ * All rights reserved. -+ * -+ * Redistribution and use in source and binary forms, with or without -+ * modification, are permitted provided that the following conditions -+ * are met: -+ * 1. Redistributions of source code must retain the above copyright -+ * notice, this list of conditions and the following disclaimer. -+ * 2. Redistributions in binary form must reproduce the above copyright -+ * notice, this list of conditions and the following disclaimer in the -+ * documentation and/or other materials provided with the distribution. -+ * 3. All advertising materials mentioning features or use of this software -+ * must display the following acknowledgement: -+ * This product includes software developed by the University of -+ * California, Berkeley and its contributors. -+ * 4. Neither the name of the University nor the names of its contributors -+ * may be used to endorse or promote products derived from this software -+ * without specific prior written permission. -+ * -+ * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND -+ * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE -+ * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE -+ * ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE -+ * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL -+ * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS -+ * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) -+ * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT -+ * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY -+ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF -+ * SUCH DAMAGE. -+ */ -+ -+/* -+ * Original Id: os-freebsd2.h,v 1.2 1996/02/15 18:53:48 mcooper Exp -+ */ -+ -+/* -+ * TEMPLATE os-*.h file -+ */ -+ -+/* -+ * Define the following name for use in #ifdef's. -+ * The value should be all upper-case with no periods (.). -+ */ -+#if !defined(NETBSD) -+#define NETBSD -+#endif -+ -+/* -+ * NOTE: NetBSD uses 64-bit file size semantics, and so you -+ * must be careful when using varargs-type functions -+ * like the *printf family when printing elements which -+ * might be 64-bits (such as stat->st_size from stat.h). -+ */ -+ -+/* -+ * Set process args to messages that show up when running ps(1) -+ * -+ * Under some OS's, the SETARGS code will cause ": is not an identifier" -+ * errors for "special" commands. -+ */ -+#define SETARGS -+ -+/* -+ * Define the type of directory routines your system has. -+ */ -+#define DIR_TYPE DIR_DIRENT -+ -+/* -+ * Determine what routines we have to get filesystem info. -+ */ -+#define FSI_TYPE FSI_GETFSSTAT -+ -+/* -+ * Type of non-blocking I/O. -+ */ -+#define NBIO_TYPE NBIO_FCNTL -+ -+/* -+ * Type of wait() function to use. -+ */ -+#define WAIT_TYPE WAIT_WAIT3 -+ -+/* -+ * Type of argument passed to wait() (above). -+ */ -+#define WAIT_ARG_TYPE int -+ -+/* -+ * Select the type of executable file format. -+ */ -+#define EXE_TYPE EXE_AOUT -+ -+/* -+ * Select the type of statfs() system call (if any). -+ */ -+#define STATFS_TYPE STATFS_BSD -+ -+/* -+ * Type of arg functions we have. -+ */ -+#define ARG_TYPE ARG_STDARG -+ -+/* -+ * UID argument type for chown() -+ */ -+typedef uid_t CHOWN_UID_T; -+ -+/* -+ * GID argument type for chown() -+ */ -+typedef gid_t CHOWN_GID_T; -+ -+/* -+ * Our types, usually these are uid_t and gid_t. -+ */ -+typedef uid_t UID_T; /* Must be signed */ -+typedef gid_t GID_T; /* Must be signed */ -+ -+/* -+ * Generic pointer, used by memcpy, malloc, etc. Usually char or void. -+ */ -+typedef void POINTER; -+ -+/* -+ * Type of set file time function available -+ */ -+#define SETFTIME_TYPE SETFTIME_UTIMES -+ -+/* -+ * Type of set line buffering function available -+ */ -+#define SETBUF_TYPE SETLINEBUF -+ -+/* -+ * Things we have -+ */ -+#define HAVE_FCHOWN /* Have fchown() */ -+#define HAVE_FCHMOD /* Have fchmod() */ -+#define HAVE_SELECT /* Have select() */ -+#define HAVE_SAVED_IDS /* Have POSIX style saved [ug]id's */ -+#define POSIX_SIGNALS /* Have POSIX signals */ -+ -+/* -+ * Things we need -+ */ -+#define NEED_UNISTD_H /* Need */ -+ -+/* -+ * Path to the remote shell command. -+ * Define this only if the pathname is different than -+ * that which appears in "include/paths.h". -+ */ -+#define _PATH_REMSH "/usr/bin/rsh" /**/ ---- src/message.c 1998/04/24 14:59:28 1.1 -+++ src/message.c 1998/04/24 15:02:47 -@@ -467,10 +467,21 @@ - (void) sprintf(tempfile, "%s/%s", cp, _RDIST_TMP); - - msgfac->mf_filename = tempfile; -+#if defined(NETBSD) -+ { -+ int fd; -+ -+ if ((fd = mkstemp(msgfac->mf_filename)) < 0 || -+ (msgfac->mf_fptr = fdopen(fd, "w")) == NULL) -+ fatalerr("Cannot open notify file for writing: %s: %s.", -+ msgfac->mf_filename, SYSERR); -+ } -+#else - (void) mktemp(msgfac->mf_filename); - if ((msgfac->mf_fptr = fopen(msgfac->mf_filename, "w"))==NULL) - fatalerr("Cannot open notify file for writing: %s: %s.", - msgfac->mf_filename, SYSERR); -+#endif - debugmsg(DM_MISC, "Created notify temp file '%s'", - msgfac->mf_filename); - } ---- mf/Makefile.var 1998/04/24 15:38:29 1.1 -+++ mf/Makefile.var 1998/04/24 15:43:39 -@@ -172,6 +172,7 @@ - config/mf.mipsos4 \ - config/mf.mipsos5 \ - config/mf.ncr \ -+ config/mf.netbsd131 \ - config/mf.nextstep2 \ - config/mf.nextstep3 \ - config/mf.osf1 \ -@@ -214,6 +215,7 @@ - config/os-mipsos4.h \ - config/os-mipsos5.h \ - config/os-ncr.h \ -+ config/os-netbsd131.h \ - config/os-nextstep2.h \ - config/os-nextstep3.h \ - config/os-osf1.h \ ---- Makefile.local 1998/04/24 15:38:29 1.1 -+++ Makefile.local 1998/04/24 15:43:39 -@@ -8,7 +8,9 @@ - # BIN_DIR variable, you would uncomment the following line - # or add your own line. - # --#BIN_DIR = /usr/bin -+BIN_DIR= ${PREFIX}/bin -+ -+CLIENT= ${RDIST6_NAME} - - # - # Add any local definitions you want pass to the compiler to DEFS_LOCAL -@@ -28,6 +30,7 @@ - # - #OPT = -O - #OPT = -+OPT= -O - - # - # You may want to use your own C Compiler (such as GCC) by enabling -@@ -45,8 +48,8 @@ - # - # Site specific Man Page configuration. - # --#MAN_1_DIR = /usr/local/man/man1 --#MAN_8_DIR = /usr/local/man/man8 -+MAN_1_DIR = ${PREFIX}/man/man1 -+MAN_8_DIR = ${PREFIX}/man/man8 - #MAN_OWNER = bin - #MAN_GROUP = bin - #MAN_MODE = 644 diff --git a/net/rdist6/patches/patch-ab b/net/rdist6/patches/patch-ab new file mode 100644 index 00000000000..c60d37f182e --- /dev/null +++ b/net/rdist6/patches/patch-ab @@ -0,0 +1,16 @@ +$NetBSD: patch-ab,v 1.1 1999/08/29 12:26:21 kim Exp $ + +--- include/defs.h.orig Mon Mar 23 18:28:14 1998 ++++ include/defs.h Sun Aug 29 07:50:07 1999 +@@ -403,7 +403,11 @@ + extern void error(char *, ...); + extern void fatalerr(char *, ...); + extern void message(int, char *, ...); ++#if defined(NETBSD) ++extern void setproctitle(const char *fmt, ...); ++#else + extern void setproctitle(char *fmt, ...); ++#endif /* NetBSD */ + #else + extern void debugmsg(); + extern void error(); diff --git a/net/rdist6/patches/patch-ac b/net/rdist6/patches/patch-ac new file mode 100644 index 00000000000..35901c4bc0c --- /dev/null +++ b/net/rdist6/patches/patch-ac @@ -0,0 +1,13 @@ +$NetBSD: patch-ac,v 1.1 1999/08/29 12:26:22 kim Exp $ + +--- include/filesys.h.orig Mon Dec 11 19:46:47 1995 ++++ include/filesys.h Sun Aug 29 07:50:07 1999 +@@ -111,7 +111,7 @@ + typedef struct statvfs statfs_t; + # define statfs(mp,sb) statvfs(mp,sb) + #else +-#if defined(BSD386) || defined(__bsdi__) || defined(FREEBSD) || STATFS_TYPE == STATFS_OSF1 ++#if defined(BSD386) || defined(__bsdi__) || defined(FREEBSD) || defined(NETBSD) || STATFS_TYPE == STATFS_OSF1 + typedef struct statfs statfs_t; + #else + # include diff --git a/net/rdist6/patches/patch-ad b/net/rdist6/patches/patch-ad new file mode 100644 index 00000000000..0ffe85b4b20 --- /dev/null +++ b/net/rdist6/patches/patch-ad @@ -0,0 +1,39 @@ +$NetBSD: patch-ad,v 1.1 1999/08/29 12:26:22 kim Exp $ + +--- src/filesys-os.c.orig Thu Feb 15 14:01:04 1996 ++++ src/filesys-os.c Sun Aug 29 07:50:07 1999 +@@ -51,7 +51,9 @@ + + #if FSI_TYPE == FSI_GETFSSTAT + static struct statfs *mnt = NULL; ++#if !defined(NETBSD) + typedef u_long ulong; ++#endif /* !NetBSD */ + #endif /* FSI_GETFSSTAT */ + + #if FSI_TYPE == FSI_MNTCTL +@@ -179,6 +181,16 @@ + if (mnt->f_flags & M_RDONLY) + mntstruct.me_flags |= MEFLAG_READONLY; + #endif ++#if defined(NETBSD) ++ if (strcmp(mnt->f_fstypename, MOUNT_NFS)) { ++ (void) sprintf(remote_dev, "%s", mnt->f_mntfromname); ++ mntstruct.me_path = remote_dev; ++ mntstruct.me_type = METYPE_NFS; ++ } else { ++ mntstruct.me_path = mnt->f_mntonname; ++ mntstruct.me_type = METYPE_OTHER; ++ } ++#else + switch ((ulong)((struct statfs*)mnt)->f_type) { + case MOUNT_NFS: + (void) sprintf(remote_dev, "%s", mnt->f_mntfromname); +@@ -190,6 +202,7 @@ + mntstruct.me_type = METYPE_OTHER; + break; + } ++#endif /* !NetBSD */ + + mnt++; + entries_left--; diff --git a/net/rdist6/patches/patch-ae b/net/rdist6/patches/patch-ae new file mode 100644 index 00000000000..c7cd1eb7c4f --- /dev/null +++ b/net/rdist6/patches/patch-ae @@ -0,0 +1,16 @@ +$NetBSD: patch-ae,v 1.1 1999/08/29 12:26:22 kim Exp $ + +--- src/setargs.c.orig Wed Feb 9 20:04:58 1994 ++++ src/setargs.c Sun Aug 29 07:50:07 1999 +@@ -130,7 +130,11 @@ + /* + * Stdarg front-end to _setproctitle() + */ ++#if defined(NETBSD) ++extern void setproctitle(const char *fmt, ...) ++#else + extern void setproctitle(char *fmt, ...) ++#endif + { + static char buf[BUFSIZ]; + va_list args; diff --git a/net/rdist6/patches/patch-af b/net/rdist6/patches/patch-af new file mode 100644 index 00000000000..4c2ee731fa4 --- /dev/null +++ b/net/rdist6/patches/patch-af @@ -0,0 +1,26 @@ +$NetBSD: patch-af,v 1.1 1999/08/29 12:26:23 kim Exp $ + +--- src/message.c.orig Fri Jul 19 13:01:56 1996 ++++ src/message.c Sun Aug 29 07:50:08 1999 +@@ -467,10 +467,21 @@ + (void) sprintf(tempfile, "%s/%s", cp, _RDIST_TMP); + + msgfac->mf_filename = tempfile; ++#if defined(NETBSD) ++ { ++ int fd; ++ ++ if ((fd = mkstemp(msgfac->mf_filename)) < 0 || ++ (msgfac->mf_fptr = fdopen(fd, "w")) == NULL) ++ fatalerr("Cannot open notify file for writing: %s: %s.", ++ msgfac->mf_filename, SYSERR); ++ } ++#else + (void) mktemp(msgfac->mf_filename); + if ((msgfac->mf_fptr = fopen(msgfac->mf_filename, "w"))==NULL) + fatalerr("Cannot open notify file for writing: %s: %s.", + msgfac->mf_filename, SYSERR); ++#endif + debugmsg(DM_MISC, "Created notify temp file '%s'", + msgfac->mf_filename); + } diff --git a/net/rdist6/patches/patch-ag b/net/rdist6/patches/patch-ag new file mode 100644 index 00000000000..bad68b110fb --- /dev/null +++ b/net/rdist6/patches/patch-ag @@ -0,0 +1,20 @@ +$NetBSD: patch-ag,v 1.1 1999/08/29 12:26:23 kim Exp $ + +--- mf/Makefile.var.orig Mon Mar 23 20:11:06 1998 ++++ mf/Makefile.var Sun Aug 29 08:00:16 1999 +@@ -172,6 +172,7 @@ + config/mf.mipsos4 \ + config/mf.mipsos5 \ + config/mf.ncr \ ++ config/mf.netbsd \ + config/mf.nextstep2 \ + config/mf.nextstep3 \ + config/mf.osf1 \ +@@ -214,6 +215,7 @@ + config/os-mipsos4.h \ + config/os-mipsos5.h \ + config/os-ncr.h \ ++ config/os-netbsd.h \ + config/os-nextstep2.h \ + config/os-nextstep3.h \ + config/os-osf1.h \ diff --git a/net/rdist6/patches/patch-ah b/net/rdist6/patches/patch-ah new file mode 100644 index 00000000000..c60bdcc985e --- /dev/null +++ b/net/rdist6/patches/patch-ah @@ -0,0 +1,34 @@ +$NetBSD: patch-ah,v 1.1 1999/08/29 12:26:23 kim Exp $ + +--- Makefile.local.orig Mon Feb 5 13:50:27 1996 ++++ Makefile.local Sun Aug 29 07:50:08 1999 +@@ -8,7 +8,9 @@ + # BIN_DIR variable, you would uncomment the following line + # or add your own line. + # +-#BIN_DIR = /usr/bin ++BIN_DIR= ${PREFIX}/bin ++ ++CLIENT= ${RDIST6_NAME} + + # + # Add any local definitions you want pass to the compiler to DEFS_LOCAL +@@ -28,6 +30,7 @@ + # + #OPT = -O + #OPT = ++OPT= -O + + # + # You may want to use your own C Compiler (such as GCC) by enabling +@@ -45,8 +48,8 @@ + # + # Site specific Man Page configuration. + # +-#MAN_1_DIR = /usr/local/man/man1 +-#MAN_8_DIR = /usr/local/man/man8 ++MAN_1_DIR = ${PREFIX}/man/man1 ++MAN_8_DIR = ${PREFIX}/man/man8 + #MAN_OWNER = bin + #MAN_GROUP = bin + #MAN_MODE = 644 -- cgit v1.2.3