1 #ifdef HAVE_SYS_TYPES_H 2 # include <sys/types.h> 3 #endif /* HAVE_SYS_TYPES_H */ 4 #ifdef HAVE_SYS_ERRNO_H 5 # include <sys/errno.h> 6 #endif /* HAVE_SYS_ERRNO_H */ 7 #ifdef HAVE_SYS_PARAM_H 8 # include <sys/param.h> 9 #endif /* HAVE_SYS_PARAM_H */ 10 #ifdef HAVE_SYS_TIME_H 11 # include <sys/time.h> 12 #endif /* HAVE_SYS_TIME_H */ 13 #ifdef HAVE_SYS_UCRED_H 14 # include <sys/ucred.h> 15 #endif /* HAVE_SYS_UCRED_H */ 16 #ifdef HAVE_SYS_SOCKET_H 17 # include <sys/socket.h> 18 #endif /* HAVE_SYS_SOCKET_H */ 19 #ifdef HAVE_NETINET_IN_H 20 # include <netinet/in.h> 21 #endif /* HAVE_NETINET_IN_H */ 22 #ifdef HAVE_NET_IF_H 23 # include <net/if.h> 24 #endif /* HAVE_NET_IF_H */ 25 #ifdef HAVE_STDIO_H 26 # include <stdio.h> 27 #endif /* HAVE_STDIO_H */ 28 29 #ifndef KERNEL 30 # define KERNEL_off_for_now_breaks_FreeBSD 31 #endif /* not KERNEL */ 32 33 #ifdef HAVE_SYS_MNTENT_H 34 # include <sys/mntent.h> 35 #endif /* HAVE_SYS_MNTENT_H */ 36 #ifdef HAVE_MNTENT_H 37 # include <mntent.h> 38 #endif /* HAVE_MNTENT_H */ 39 #ifdef HAVE_SYS_MNTTAB_H 40 # include <sys/mnttab.h> 41 #endif /* HAVE_SYS_MNTTAB_H */ 42 #if defined(HAVE_MNTTAB_H) && !defined(MNTTAB) 43 /* 44 * Do not include it if MNTTAB is already defined because it probably 45 * came from <sys/mnttab.h> and we do not want conflicting definitions. 46 */ 47 # include <mnttab.h> 48 #endif /* defined(HAVE_MNTTAB_H) && !defined(MNTTAB) */ 49 50 #ifdef HAVE_SYS_MOUNT_H 51 # ifndef NFSCLIENT 52 # define NFSCLIENT 53 # endif /* not NFSCLIENT */ 54 # ifndef PCFS 55 # define PCFS 56 # endif /* not PCFS */ 57 # ifndef LOFS 58 # define LOFS 59 # endif /* not LOFS */ 60 # ifndef RFS 61 # define RFS 62 # endif /* not RFS */ 63 # ifndef MSDOSFS 64 # define MSDOSFS 65 # endif /* not MSDOSFS */ 66 # ifndef MFS 67 # define MFS 1 68 # endif /* not MFS */ 69 # ifndef CD9660 70 # define CD9660 71 # endif /* not CD9660 */ 72 # ifndef NFS 73 # define NFS 74 # endif /* not NFS */ 75 # include <sys/mount.h> 76 #endif /* HAVE_SYS_MOUNT_H */ 77 78 #ifdef HAVE_SYS_VMOUNT_H 79 # include <sys/vmount.h> 80 #endif /* HAVE_SYS_VMOUNT_H */ 81 82 /* 83 * There is no point in including this on a glibc2 system 84 * we're only asking for trouble 85 */ 86 #if defined HAVE_LINUX_FS_H && (!defined __GLIBC__ || __GLIBC__ < 2) 87 /* 88 * There's a conflict of definitions on redhat alpha linux between 89 * <netinet/in.h> and <linux/fs.h>. 90 * Also a conflict in definitions of ntohl/htonl in RH-5.1 sparc64 91 * between <netinet/in.h> and <linux/byteorder/generic.h> (2.1 kernels). 92 */ 93 # ifdef HAVE_SOCKETBITS_H 94 # define _LINUX_SOCKET_H 95 # undef BLKFLSBUF 96 # undef BLKGETSIZE 97 # undef BLKRAGET 98 # undef BLKRASET 99 # undef BLKROGET 100 # undef BLKROSET 101 # undef BLKRRPART 102 # undef MS_MGC_VAL 103 # undef MS_RMT_MASK 104 # endif /* HAVE_SOCKETBITS_H */ 105 # ifdef HAVE_LINUX_POSIX_TYPES_H 106 # include <linux/posix_types.h> 107 # endif /* HAVE_LINUX_POSIX_TYPES_H */ 108 # ifndef _LINUX_BYTEORDER_GENERIC_H 109 # define _LINUX_BYTEORDER_GENERIC_H 110 # endif /* _LINUX_BYTEORDER_GENERIC_H */ 111 # ifndef _LINUX_STRING_H_ 112 # define _LINUX_STRING_H_ 113 # endif /* not _LINUX_STRING_H_ */ 114 # ifdef HAVE_LINUX_KDEV_T_H 115 # define __KERNEL__ 116 # include <linux/kdev_t.h> 117 # undef __KERNEL__ 118 # endif /* HAVE_LINUX_KDEV_T_H */ 119 # ifdef HAVE_LINUX_LIST_H 120 # define __KERNEL__ 121 # include <linux/list.h> 122 # undef __KERNEL__ 123 # endif /* HAVE_LINUX_LIST_H */ 124 # include <linux/fs.h> 125 #endif /* HAVE_LINUX_FS_H && (!__GLIBC__ || __GLIBC__ < 2) */ 126 127 #ifdef HAVE_SYS_FS_TYPES_H 128 # include <sys/fs_types.h> 129 #endif /* HAVE_SYS_FS_TYPES_H */ 130 131 #ifdef HAVE_UFS_UFS_MOUNT_H 132 # include <ufs/ufs_mount.h> 133 #endif /* HAVE_UFS_UFS_MOUNT_H */ 134 #ifdef HAVE_UFS_UFS_UFSMOUNT_H 135 # ifndef MAXQUOTAS 136 # define MAXQUOTAS 2 137 # endif /* not MAXQUOTAS */ 138 struct netexport { int this_is_SO_wrong; }; /* for bsdi-2.1 */ 139 /* netbsd-1.4 does't protect <ufs/ufs/ufsmount.h> */ 140 # ifndef _UFS_UFS_UFSMOUNT_H 141 # include <ufs/ufs/ufsmount.h> 142 # define _UFS_UFS_UFSMOUNT_H 143 # endif /* not _UFS_UFS_UFSMOUNT_H */ 144 #endif /* HAVE_UFS_UFS_UFSMOUNT_H */ 145 146 #ifdef HAVE_CDFS_CDFS_MOUNT_H 147 # include <cdfs/cdfs_mount.h> 148 #endif /* HAVE_CDFS_CDFS_MOUNT_H */ 149 #ifdef HAVE_CDFS_CDFSMOUNT_H 150 # include <cdfs/cdfsmount.h> 151 #endif /* HAVE_CDFS_CDFSMOUNT_H */ 152 #ifdef HAVE_ISOFS_CD9660_CD9660_MOUNT_H 153 # include <isofs/cd9660/cd9660_mount.h> 154 #endif /* HAVE_ISOFS_CD9660_CD9660_MOUNT_H */ 155 156 #ifdef HAVE_RPC_RPC_H 157 # include <rpc/rpc.h> 158 #endif /* HAVE_RPC_RPC_H */ 159 #ifdef HAVE_RPC_TYPES_H 160 # include <rpc/types.h> 161 #endif /* HAVE_RPC_TYPES_H */ 162 /* Prevent multiple inclusion on Ultrix 4 */ 163 #if defined(HAVE_RPC_XDR_H) && !defined(__XDR_HEADER__) 164 # include <rpc/xdr.h> 165 #endif /* defined(HAVE_RPC_XDR_H) && !defined(__XDR_HEADER__) */ 166 167 /* ALWAYS INCLUDE AM-UTILS' SPECIFIC NFS PROTOCOL HEADER NEXT! */ 168