]> CyberLeo.Net >> Repos - FreeBSD/releng/9.2.git/blob - contrib/amd/include/mount_headers1.h
- Copy stable/9 to releng/9.2 as part of the 9.2-RELEASE cycle.
[FreeBSD/releng/9.2.git] / contrib / amd / include / mount_headers1.h
1 /*
2  * Copyright (c) 1997-2006 Erez Zadok
3  * Copyright (c) 1990 Jan-Simon Pendry
4  * Copyright (c) 1990 Imperial College of Science, Technology & Medicine
5  * Copyright (c) 1990 The Regents of the University of California.
6  * All rights reserved.
7  *
8  * This code is derived from software contributed to Berkeley by
9  * Jan-Simon Pendry at Imperial College, London.
10  *
11  * Redistribution and use in source and binary forms, with or without
12  * modification, are permitted provided that the following conditions
13  * are met:
14  * 1. Redistributions of source code must retain the above copyright
15  *    notice, this list of conditions and the following disclaimer.
16  * 2. Redistributions in binary form must reproduce the above copyright
17  *    notice, this list of conditions and the following disclaimer in the
18  *    documentation and/or other materials provided with the distribution.
19  * 3. All advertising materials mentioning features or use of this software
20  *    must display the following acknowledgment:
21  *      This product includes software developed by the University of
22  *      California, Berkeley and its contributors.
23  * 4. Neither the name of the University nor the names of its contributors
24  *    may be used to endorse or promote products derived from this software
25  *    without specific prior written permission.
26  *
27  * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
28  * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
29  * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
30  * ARE DISCLAIMED.  IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
31  * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
32  * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
33  * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
34  * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
35  * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
36  * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
37  * SUCH DAMAGE.
38  *
39  *
40  * File: am-utils/include/mount_headers1.h
41  *
42  */
43
44
45 #ifdef HAVE_SYS_TYPES_H
46 # include <sys/types.h>
47 #endif /* HAVE_SYS_TYPES_H */
48 #ifdef HAVE_SYS_ERRNO_H
49 # include <sys/errno.h>
50 #endif /* HAVE_SYS_ERRNO_H */
51 #ifdef HAVE_SYS_PARAM_H
52 # include <sys/param.h>
53 #endif /* HAVE_SYS_PARAM_H */
54 #ifdef HAVE_SYS_TIME_H
55 # include <sys/time.h>
56 #endif /* HAVE_SYS_TIME_H */
57 #ifdef HAVE_SYS_UCRED_H
58 # include <sys/ucred.h>
59 #endif /* HAVE_SYS_UCRED_H */
60 #ifdef HAVE_SYS_SOCKET_H
61 # include <sys/socket.h>
62 #endif /* HAVE_SYS_SOCKET_H */
63 #ifdef HAVE_NETINET_IN_H
64 # include <netinet/in.h>
65 #endif /* HAVE_NETINET_IN_H */
66 #ifdef HAVE_NET_IF_H
67 # include <net/if.h>
68 #endif /* HAVE_NET_IF_H */
69 #ifdef HAVE_STDIO_H
70 # include <stdio.h>
71 #endif /* HAVE_STDIO_H */
72
73 #ifndef KERNEL
74 # define KERNEL_off_for_now_breaks_FreeBSD
75 #endif /* not KERNEL */
76
77 #ifdef HAVE_SYS_MNTENT_H
78 # include <sys/mntent.h>
79 #endif /* HAVE_SYS_MNTENT_H */
80 #ifdef HAVE_MNTENT_H
81 # include <mntent.h>
82 #endif /* HAVE_MNTENT_H */
83 #ifdef HAVE_SYS_MNTTAB_H
84 # include <sys/mnttab.h>
85 #endif /* HAVE_SYS_MNTTAB_H */
86 #if defined(HAVE_MNTTAB_H) && !defined(MNTTAB)
87 /*
88  * Do not include it if MNTTAB is already defined because it probably
89  * came from <sys/mnttab.h> and we do not want conflicting definitions.
90  */
91 # include <mnttab.h>
92 #endif /* defined(HAVE_MNTTAB_H) && !defined(MNTTAB) */
93
94 #ifdef HAVE_SYS_MOUNT_H
95 # ifndef NFSCLIENT
96 #  define NFSCLIENT
97 # endif /* not NFSCLIENT */
98 # ifndef PCFS
99 #  define PCFS
100 # endif /* not PCFS */
101 # ifndef LOFS
102 #  define LOFS
103 # endif /* not LOFS */
104 # ifndef RFS
105 #  define RFS
106 # endif /* not RFS */
107 # ifndef MSDOSFS
108 #  define MSDOSFS
109 # endif /* not MSDOSFS */
110 # ifndef MFS
111 #  define MFS 1
112 # endif /* not MFS */
113 # ifndef CD9660
114 #  define CD9660
115 # endif /* not CD9660 */
116 # ifndef NFS
117 #  define NFS
118 # endif /* not NFS */
119 # include <sys/mount.h>
120 #endif /* HAVE_SYS_MOUNT_H */
121
122 #ifdef HAVE_SYS_VMOUNT_H
123 # include <sys/vmount.h>
124 #endif /* HAVE_SYS_VMOUNT_H */
125
126 /*
127  * There is no point in including this on a glibc2 system
128  * we're only asking for trouble
129  */
130 #if defined HAVE_LINUX_FS_H && (!defined __GLIBC__ || __GLIBC__ < 2)
131 /*
132  * There's a conflict of definitions on redhat alpha linux between
133  * <netinet/in.h> and <linux/fs.h>.
134  * Also a conflict in definitions of ntohl/htonl in RH-5.1 sparc64
135  * between <netinet/in.h> and <linux/byteorder/generic.h> (2.1 kernels).
136  */
137 # ifdef HAVE_SOCKETBITS_H
138 #  define _LINUX_SOCKET_H
139 #  undef BLKFLSBUF
140 #  undef BLKGETSIZE
141 #  undef BLKRAGET
142 #  undef BLKRASET
143 #  undef BLKROGET
144 #  undef BLKROSET
145 #  undef BLKRRPART
146 #  undef MS_MGC_VAL
147 #  undef MS_RMT_MASK
148 # endif /* HAVE_SOCKETBITS_H */
149 # ifdef HAVE_LINUX_POSIX_TYPES_H
150 #  include <linux/posix_types.h>
151 # endif /* HAVE_LINUX_POSIX_TYPES_H */
152 # ifndef _LINUX_BYTEORDER_GENERIC_H
153 #  define _LINUX_BYTEORDER_GENERIC_H
154 # endif /* _LINUX_BYTEORDER_GENERIC_H */
155 # ifndef _LINUX_STRING_H_
156 #  define _LINUX_STRING_H_
157 # endif /* not _LINUX_STRING_H_ */
158 # ifdef HAVE_LINUX_KDEV_T_H
159 #  define __KERNEL__
160 #  include <linux/kdev_t.h>
161 #  undef __KERNEL__
162 # endif /* HAVE_LINUX_KDEV_T_H */
163 # ifdef HAVE_LINUX_LIST_H
164 #  define __KERNEL__
165 #  include <linux/list.h>
166 #  undef __KERNEL__
167 # endif /* HAVE_LINUX_LIST_H */
168 # include <linux/fs.h>
169 #endif /* HAVE_LINUX_FS_H && (!__GLIBC__ || __GLIBC__ < 2) */
170
171 #ifdef HAVE_SYS_FS_TYPES_H
172 # include <sys/fs_types.h>
173 #endif /* HAVE_SYS_FS_TYPES_H */
174
175 #ifdef HAVE_UFS_UFS_MOUNT_H
176 # include <ufs/ufs_mount.h>
177 #endif /* HAVE_UFS_UFS_MOUNT_H */
178 #ifdef  HAVE_UFS_UFS_UFSMOUNT_H_off
179 # error do not include this file here because on *bsd it
180 # error causes errors with other header files.  Instead, add it to the
181 # error specific conf/nfs_prot_*.h file.
182 # include <ufs/ufs/ufsmount.h>
183 #endif  /* HAVE_UFS_UFS_UFSMOUNT_H_off */
184
185 #ifdef HAVE_CDFS_CDFS_MOUNT_H
186 # include <cdfs/cdfs_mount.h>
187 #endif /* HAVE_CDFS_CDFS_MOUNT_H */
188 #ifdef HAVE_CDFS_CDFSMOUNT_H
189 # include <cdfs/cdfsmount.h>
190 #endif /* HAVE_CDFS_CDFSMOUNT_H */
191 #ifdef HAVE_ISOFS_CD9660_CD9660_MOUNT_H
192 # include <isofs/cd9660/cd9660_mount.h>
193 #endif /* HAVE_ISOFS_CD9660_CD9660_MOUNT_H */
194
195 #ifdef HAVE_SYS_FS_PC_FS_H
196 # include <sys/fs/pc_fs.h>
197 #endif /* HAVE_SYS_FS_PC_FS_H */
198 #ifdef HAVE_MSDOSFS_MSDOSFSMOUNT_H
199 # include <msdosfs/msdosfsmount.h>
200 #endif /* HAVE_MSDOSFS_MSDOSFSMOUNT_H */
201 #ifdef HAVE_FS_MSDOSFS_MSDOSFSMOUNT_H
202 # include <fs/msdosfs/msdosfsmount.h>
203 #endif /* HAVE_FS_MSDOSFS_MSDOSFSMOUNT_H */
204
205 #ifdef HAVE_RPC_RPC_H
206 # include <rpc/rpc.h>
207 #endif /* HAVE_RPC_RPC_H */
208 #ifdef HAVE_RPC_TYPES_H
209 # include <rpc/types.h>
210 #endif /* HAVE_RPC_TYPES_H */
211 /* Prevent multiple inclusion on Ultrix 4 */
212 #if defined(HAVE_RPC_XDR_H) && !defined(__XDR_HEADER__)
213 # include <rpc/xdr.h>
214 #endif /* defined(HAVE_RPC_XDR_H) && !defined(__XDR_HEADER__) */
215
216 /* ALWAYS INCLUDE AM-UTILS' SPECIFIC NFS PROTOCOL HEADER NEXT! */