]>
Commit | Line | Data |
---|---|---|
e5fd101c PS |
1 | autofs-5.0.4 - fix kernel includes |
2 | ||
3 | From: Valerie Aurora Henson <vaurora@redhat.com> | |
4 | ||
5 | autofs_dev-ioctl.h is included by both the kernel module and autofs, | |
6 | and it includes two kernel header files. The compile worked if the | |
7 | kernel headers were installed but failed otherwise. | |
8 | ||
9 | imk: there are a couple of other instances were we include kernel | |
10 | headers. I've tried to fix that up too. | |
11 | --- | |
12 | ||
13 | CHANGELOG | 1 + | |
14 | include/automount.h | 3 +-- | |
15 | include/dev-ioctl-lib.h | 3 +-- | |
16 | include/linux/auto_dev-ioctl.h | 7 ++++++- | |
17 | include/linux/auto_fs.h | 6 ++++-- | |
18 | 5 files changed, 13 insertions(+), 7 deletions(-) | |
19 | ||
20 | ||
21 | diff --git a/CHANGELOG b/CHANGELOG | |
22 | index a42dd14..387af5e 100644 | |
23 | --- a/CHANGELOG | |
24 | +++ b/CHANGELOG | |
25 | @@ -42,6 +42,7 @@ | |
26 | - zero s_magic is valid. | |
27 | - use percent hack for master map keys. | |
28 | - use intr option as hosts mount default. | |
29 | +- fix kernel includes. | |
30 | ||
31 | 4/11/2008 autofs-5.0.4 | |
32 | ----------------------- | |
33 | diff --git a/include/automount.h b/include/automount.h | |
34 | index 615e07d..d4675bd 100644 | |
35 | --- a/include/automount.h | |
36 | +++ b/include/automount.h | |
37 | @@ -8,12 +8,11 @@ | |
38 | #ifndef AUTOMOUNT_H | |
39 | #define AUTOMOUNT_H | |
40 | ||
41 | -#include <sys/types.h> | |
42 | #include <paths.h> | |
43 | #include <limits.h> | |
44 | #include <time.h> | |
45 | #include <syslog.h> | |
46 | -#include <linux/types.h> | |
47 | +#include <sys/types.h> | |
48 | #include <pthread.h> | |
49 | #include <sched.h> | |
50 | #include <errno.h> | |
51 | diff --git a/include/dev-ioctl-lib.h b/include/dev-ioctl-lib.h | |
52 | index b7b8211..6d35da2 100644 | |
53 | --- a/include/dev-ioctl-lib.h | |
54 | +++ b/include/dev-ioctl-lib.h | |
55 | @@ -21,8 +21,7 @@ | |
56 | #ifndef AUTOFS_DEV_IOCTL_LIB_H | |
57 | #define AUTOFS_DEV_IOCTL_LIB_H | |
58 | ||
59 | -#include <sys/types.h> | |
60 | -#include "linux/auto_dev-ioctl.h" | |
61 | +#include <linux/auto_dev-ioctl.h> | |
62 | ||
63 | #define CONTROL_DEVICE "/dev/autofs" | |
64 | ||
65 | diff --git a/include/linux/auto_dev-ioctl.h b/include/linux/auto_dev-ioctl.h | |
66 | index 91a7739..850f39b 100644 | |
67 | --- a/include/linux/auto_dev-ioctl.h | |
68 | +++ b/include/linux/auto_dev-ioctl.h | |
69 | @@ -10,8 +10,13 @@ | |
70 | #ifndef _LINUX_AUTO_DEV_IOCTL_H | |
71 | #define _LINUX_AUTO_DEV_IOCTL_H | |
72 | ||
73 | +#include <linux/auto_fs.h> | |
74 | + | |
75 | +#ifdef __KERNEL__ | |
76 | #include <linux/string.h> | |
77 | -#include <linux/types.h> | |
78 | +#else | |
79 | +#include <string.h> | |
80 | +#endif /* __KERNEL__ */ | |
81 | ||
82 | #define AUTOFS_DEVICE_NAME "autofs" | |
83 | ||
84 | diff --git a/include/linux/auto_fs.h b/include/linux/auto_fs.h | |
85 | index bd39f09..91d414f 100644 | |
86 | --- a/include/linux/auto_fs.h | |
87 | +++ b/include/linux/auto_fs.h | |
88 | @@ -17,11 +17,13 @@ | |
89 | #ifdef __KERNEL__ | |
90 | #include <linux/fs.h> | |
91 | #include <linux/limits.h> | |
92 | +#include <linux/types.h> | |
93 | +#include <linux/ioctl.h> | |
94 | +#else | |
95 | #include <asm/types.h> | |
96 | +#include <sys/ioctl.h> | |
97 | #endif /* __KERNEL__ */ | |
98 | ||
99 | -#include <linux/ioctl.h> | |
100 | - | |
101 | /* This file describes autofs v3 */ | |
102 | #define AUTOFS_PROTO_VERSION 3 | |
103 |