1*47534Spendry /* $Id: os-bsd44.h,v 5.2.1.2 90/11/04 23:17:39 jsp Exp $ */ 244630Smckusick 344630Smckusick /* 444630Smckusick * 4.4 BSD definitions for Amd (automounter) 544630Smckusick * 644630Smckusick * Copyright (c) 1990 Jan-Simon Pendry 744630Smckusick * Copyright (c) 1990 Imperial College of Science, Technology & Medicine 844630Smckusick * Copyright (c) 1990 The Regents of the University of California. 944630Smckusick * All rights reserved. 1044630Smckusick * 1144630Smckusick * This code is derived from software contributed to Berkeley by 1244630Smckusick * Jan-Simon Pendry at Imperial College, London. 1344630Smckusick * 1444630Smckusick * %sccs.include.redist.c% 1544630Smckusick * 16*47534Spendry * @(#)os-bsd44.h 5.2 (Berkeley) 03/17/91 1744630Smckusick */ 1844630Smckusick 1944630Smckusick /* 2044630Smckusick * Does the compiler grok void * 2144630Smckusick */ 2244630Smckusick #define VOIDP 2344630Smckusick 2444630Smckusick /* 2544630Smckusick * Which version of the Sun RPC library we are using 2644630Smckusick * This is the implementation release number, not 2744630Smckusick * the protocol revision number. 2844630Smckusick */ 29*47534Spendry #define RPC_4 3044630Smckusick 3144630Smckusick /* 3244630Smckusick * Which version of the NFS interface are we using. 3344630Smckusick * This is the implementation release number, not 3444630Smckusick * the protocol revision number. 3544630Smckusick */ 3644630Smckusick #define NFS_44 3744630Smckusick #define HAS_TCP_NFS 3844630Smckusick 3944630Smckusick /* 4044630Smckusick * Does this OS have NDBM support? 4144630Smckusick */ 4244630Smckusick #define OS_HAS_NDBM 4344630Smckusick 4444630Smckusick /* 45*47534Spendry * 4.4 doesn't provide NIS. 46*47534Spendry */ 47*47534Spendry #undef HAS_NIS_MAPS 48*47534Spendry 49*47534Spendry /* 5044630Smckusick * The mount table is obtained from the kernel 5144630Smckusick */ 5244630Smckusick #undef UPDATE_MTAB 5344630Smckusick 5444630Smckusick /* 5544630Smckusick * No mntent info on 4.4 BSD 5644630Smckusick */ 5744630Smckusick #undef MNTENT_HDR 5844630Smckusick 5944630Smckusick /* 6044630Smckusick * Name of filesystem types 6144630Smckusick */ 6244630Smckusick #define MOUNT_TYPE_NFS MOUNT_NFS 6344630Smckusick #define MOUNT_TYPE_UFS MOUNT_UFS 6444630Smckusick #undef MTAB_TYPE_UFS 6544630Smckusick #define MTAB_TYPE_UFS "ufs" 6644630Smckusick #define MTAB_TYPE_MFS "mfs" 6744630Smckusick 6844630Smckusick /* 6944630Smckusick * How to unmount filesystems 7044630Smckusick */ 7144630Smckusick #undef UNMOUNT_TRAP 7244630Smckusick #undef NEED_UMOUNT_FS 7344630Smckusick #define NEED_UMOUNT_BSD 7444630Smckusick 7544630Smckusick /* 7644630Smckusick * How to copy an address into an NFS filehandle 7744630Smckusick */ 7844630Smckusick #undef NFS_SA_DREF 7944630Smckusick #define NFS_SA_DREF(dst, src) { \ 8044630Smckusick (dst).addr = (struct sockaddr *) (src); \ 8144630Smckusick (dst).sotype = SOCK_DGRAM; \ 8244630Smckusick (dst).proto = 0; \ 8344630Smckusick } 8444630Smckusick 8544630Smckusick /* 8644630Smckusick * Byte ordering 8744630Smckusick */ 8844630Smckusick #ifndef BYTE_ORDER 8944630Smckusick #include <machine/endian.h> 9044630Smckusick #endif /* BYTE_ORDER */ 9144630Smckusick 9244630Smckusick #undef ARCH_ENDIAN 9344630Smckusick #if BYTE_ORDER == LITTLE_ENDIAN 9444630Smckusick #define ARCH_ENDIAN "little" 9544630Smckusick #else 9644630Smckusick #if BYTE_ORDER == BIG_ENDIAN 9744630Smckusick #define ARCH_ENDIAN "big" 9844630Smckusick #else 9944630Smckusick XXX - Probably no hope of running Amd on this machine! 10044630Smckusick #endif /* BIG */ 10144630Smckusick #endif /* LITTLE */ 10244630Smckusick 10344630Smckusick /* 10444630Smckusick * Miscellaneous 4.4 BSD bits 10544630Smckusick */ 10644630Smckusick #define NEED_MNTOPT_PARSER 10744630Smckusick #define SHORT_MOUNT_NAME 10844630Smckusick 10944630Smckusick #define MNTMAXSTR 128 11044630Smckusick 11144630Smckusick #define MNTTYPE_UFS "ufs" /* Un*x file system */ 11244630Smckusick #define MNTTYPE_NFS "nfs" /* network file system */ 11344630Smckusick #define MNTTYPE_MFS "mfs" /* memory file system */ 11444630Smckusick #define MNTTYPE_IGNORE "ignore" /* No type specified, ignore this entry */ 11544630Smckusick 11644630Smckusick #define M_RDONLY MNT_RDONLY 11744630Smckusick #define M_SYNC MNT_SYNCHRONOUS 11844630Smckusick #define M_NOEXEC MNT_NOEXEC 11944630Smckusick #define M_NOSUID MNT_NOSUID 12044630Smckusick #define M_NODEV MNT_NODEV 12144630Smckusick 12244630Smckusick #define MNTOPT_SOFT "soft" /* soft mount */ 12344630Smckusick #define MNTOPT_INTR "intr" /* interrupts allowed */ 12444630Smckusick 12544630Smckusick struct mntent { 12644630Smckusick char *mnt_fsname; /* name of mounted file system */ 12744630Smckusick char *mnt_dir; /* file system path prefix */ 12844630Smckusick char *mnt_type; /* MNTTYPE_* */ 12944630Smckusick char *mnt_opts; /* MNTOPT* */ 13044630Smckusick int mnt_freq; /* dump frequency, in days */ 13144630Smckusick int mnt_passno; /* pass number on parallel fsck */ 13244630Smckusick }; 13344630Smckusick 13444630Smckusick /* 13544630Smckusick * Type of a file handle 13644630Smckusick */ 13744630Smckusick #undef NFS_FH_TYPE 13844630Smckusick #define NFS_FH_TYPE nfsv2fh_t * 13944630Smckusick 14044630Smckusick /* 14144630Smckusick * How to get a mount list 14244630Smckusick */ 14344630Smckusick #undef READ_MTAB_FROM_FILE 14444630Smckusick #define READ_MTAB_BSD_STYLE 14544630Smckusick 14644630Smckusick /* 14744630Smckusick * The data for the mount syscall needs the path in addition to the 14844630Smckusick * host name since that is the only source of information about the 14944630Smckusick * mounted filesystem. 15044630Smckusick */ 15144630Smckusick #define NFS_ARGS_NEEDS_PATH 152*47534Spendry 153*47534Spendry /* 154*47534Spendry * 4.4 has RE support built in 155*47534Spendry */ 156*47534Spendry #undef RE_HDR 157*47534Spendry #define RE_HDR <regexp.h> 158