Merge with Linux 2.4.0-test5-pre1. This works again on Origin UP.
[linux-2.6/linux-mips.git] / fs / Makefile
blob7573a7f9595d08e4eae5e021bddab9cb8f39378e
2 # Makefile for the Linux filesystems.
4 # Note! Dependencies are done automagically by 'make dep', which also
5 # removes any old dependencies. DON'T put your own dependencies here
6 # unless it's something special (not a .c file).
8 # Note 2! The CFLAGS definitions are now in the main makefile.
10 FILESYSTEMS = $(join $(SUB_DIRS),$(SUB_DIRS:%=/%.o))
11 O_TARGET := fs.o
12 O_OBJS = open.o read_write.o devices.o file_table.o buffer.o \
13 super.o block_dev.o stat.o exec.o pipe.o namei.o fcntl.o \
14 ioctl.o readdir.o select.o fifo.o locks.o filesystems.o \
15 dcache.o inode.o attr.o bad_inode.o file.o iobuf.o \
16 $(BINFMTS) $(FILESYSTEMS)
18 MOD_LIST_NAME := FS_MODULES
19 ALL_SUB_DIRS = coda minix ext2 fat msdos vfat proc isofs nfs umsdos ntfs \
20 hpfs sysv smbfs ncpfs ufs efs affs romfs autofs hfs lockd \
21 nfsd nls devpts devfs adfs partitions qnx4 udf bfs cramfs \
22 openpromfs autofs4 ramfs jffs
24 SUB_DIRS :=
26 ifeq ($(CONFIG_QUOTA),y)
27 O_OBJS += dquot.o
28 else
29 O_OBJS += noquot.o
30 endif
32 ifdef CONFIG_PROC_FS
33 SUB_DIRS += proc
34 endif
36 SUB_DIRS += partitions
38 # Do not add any filesystems before this line
40 ifeq ($(CONFIG_EXT2_FS),y)
41 SUB_DIRS += ext2
42 else
43 ifeq ($(CONFIG_EXT2_FS),m)
44 MOD_SUB_DIRS += ext2
45 endif
46 endif
48 ifeq ($(CONFIG_CRAMFS),y)
49 SUB_DIRS += cramfs
50 else
51 ifeq ($(CONFIG_CRAMFS),m)
52 MOD_SUB_DIRS += cramfs
53 endif
54 endif
56 ifeq ($(CONFIG_RAMFS),y)
57 SUB_DIRS += ramfs
58 else
59 ifeq ($(CONFIG_RAMFS),m)
60 MOD_SUB_DIRS += ramfs
61 endif
62 endif
64 ifeq ($(CONFIG_CODA_FS),y)
65 SUB_DIRS += coda
66 else
67 ifeq ($(CONFIG_CODA_FS),m)
68 MOD_SUB_DIRS += coda
69 endif
70 endif
72 ifeq ($(CONFIG_MINIX_FS),y)
73 SUB_DIRS += minix
74 else
75 ifeq ($(CONFIG_MINIX_FS),m)
76 MOD_SUB_DIRS += minix
77 endif
78 endif
80 ifeq ($(CONFIG_FAT_FS),y)
81 SUB_DIRS += fat
82 else
83 ifeq ($(CONFIG_FAT_FS),m)
84 MOD_SUB_DIRS += fat
85 endif
86 endif
88 ifeq ($(CONFIG_MSDOS_FS),y)
89 SUB_DIRS += msdos
90 else
91 ifeq ($(CONFIG_MSDOS_FS),m)
92 MOD_SUB_DIRS += msdos
93 endif
94 endif
96 ifeq ($(CONFIG_VFAT_FS),y)
97 SUB_DIRS += vfat
98 else
99 ifeq ($(CONFIG_VFAT_FS),m)
100 MOD_SUB_DIRS += vfat
101 endif
102 endif
104 ifeq ($(CONFIG_BFS_FS),y)
105 SUB_DIRS += bfs
106 else
107 ifeq ($(CONFIG_BFS_FS),m)
108 MOD_SUB_DIRS += bfs
109 endif
110 endif
112 ifeq ($(CONFIG_ISO9660_FS),y)
113 SUB_DIRS += isofs
114 else
115 ifeq ($(CONFIG_ISO9660_FS),m)
116 MOD_SUB_DIRS += isofs
117 endif
118 endif
120 ifdef CONFIG_DEVFS_FS
121 SUB_DIRS += devfs
122 endif
124 ifeq ($(CONFIG_HFS_FS),y)
125 SUB_DIRS += hfs
126 else
127 ifeq ($(CONFIG_HFS_FS),m)
128 MOD_SUB_DIRS += hfs
129 endif
130 endif
132 ifeq ($(CONFIG_NFS_FS),y)
133 SUB_DIRS += nfs
134 else
135 ifeq ($(CONFIG_NFS_FS),m)
136 MOD_SUB_DIRS += nfs
137 endif
138 endif
140 ifeq ($(CONFIG_NFSD),y)
141 CONFIG_LOCKD := y
142 SUB_DIRS += nfsd
143 else
144 ifeq ($(CONFIG_NFSD),m)
145 MOD_SUB_DIRS += nfsd
146 endif
147 endif
149 ifeq ($(CONFIG_LOCKD),y)
150 SUB_DIRS += lockd
151 else
152 ifeq ($(CONFIG_LOCKD),m)
153 MOD_SUB_DIRS := lockd $(MOD_SUB_DIRS)
154 endif
155 endif
157 # Since CONFIG_NLS might be set to y while there are modules
158 # to be build in the nls/ directory, we need to enter the nls
159 # directory every time, but with different rules.
160 ifeq ($(CONFIG_NLS),y)
161 SUB_DIRS += nls
162 MOD_IN_SUB_DIRS += nls
163 else
164 ifeq ($(CONFIG_NLS),m)
165 MOD_SUB_DIRS += nls
166 endif
167 endif
169 ifeq ($(CONFIG_UMSDOS_FS),y)
170 SUB_DIRS += umsdos
171 else
172 ifeq ($(CONFIG_UMSDOS_FS),m)
173 MOD_SUB_DIRS += umsdos
174 endif
175 endif
177 ifeq ($(CONFIG_SYSV_FS),y)
178 SUB_DIRS += sysv
179 else
180 ifeq ($(CONFIG_SYSV_FS),m)
181 MOD_SUB_DIRS += sysv
182 endif
183 endif
185 ifeq ($(CONFIG_SMB_FS),y)
186 SUB_DIRS += smbfs
187 else
188 ifeq ($(CONFIG_SMB_FS),m)
189 MOD_SUB_DIRS += smbfs
190 endif
191 endif
193 ifeq ($(CONFIG_NCP_FS),y)
194 SUB_DIRS += ncpfs
195 else
196 ifeq ($(CONFIG_NCP_FS),m)
197 MOD_SUB_DIRS += ncpfs
198 endif
199 endif
201 ifeq ($(CONFIG_HPFS_FS),y)
202 SUB_DIRS += hpfs
203 else
204 ifeq ($(CONFIG_HPFS_FS),m)
205 MOD_SUB_DIRS += hpfs
206 endif
207 endif
209 ifeq ($(CONFIG_NTFS_FS),y)
210 SUB_DIRS += ntfs
211 else
212 ifeq ($(CONFIG_NTFS_FS),m)
213 MOD_SUB_DIRS += ntfs
214 endif
215 endif
217 ifeq ($(CONFIG_UFS_FS),y)
218 SUB_DIRS += ufs
219 else
220 ifeq ($(CONFIG_UFS_FS),m)
221 MOD_SUB_DIRS += ufs
222 endif
223 endif
225 ifeq ($(CONFIG_EFS_FS),y)
226 SUB_DIRS += efs
227 else
228 ifeq ($(CONFIG_EFS_FS),m)
229 MOD_SUB_DIRS += efs
230 endif
231 endif
233 ifeq ($(CONFIG_JFFS_FS),y)
234 SUB_DIRS += jffs
235 else
236 ifeq ($(CONFIG_JFFS_FS),m)
237 MOD_SUB_DIRS += jffs
238 endif
239 endif
241 ifeq ($(CONFIG_AFFS_FS),y)
242 SUB_DIRS += affs
243 else
244 ifeq ($(CONFIG_AFFS_FS),m)
245 MOD_SUB_DIRS += affs
246 endif
247 endif
249 ifeq ($(CONFIG_ROMFS_FS),y)
250 SUB_DIRS += romfs
251 else
252 ifeq ($(CONFIG_ROMFS_FS),m)
253 MOD_SUB_DIRS += romfs
254 endif
255 endif
257 ifeq ($(CONFIG_QNX4FS_FS),y)
258 SUB_DIRS += qnx4
259 else
260 ifeq ($(CONFIG_QNX4FS_FS),m)
261 MOD_SUB_DIRS += qnx4
262 endif
263 endif
265 ifeq ($(CONFIG_UDF_FS),y)
266 SUB_DIRS += udf
267 else
268 ifeq ($(CONFIG_UDF_FS),m)
269 MOD_SUB_DIRS += udf
270 endif
271 endif
273 ifeq ($(CONFIG_AUTOFS_FS),y)
274 SUB_DIRS += autofs
275 else
276 ifeq ($(CONFIG_AUTOFS_FS),m)
277 MOD_SUB_DIRS += autofs
278 endif
279 endif
281 ifeq ($(CONFIG_AUTOFS4_FS),y)
282 SUB_DIRS += autofs4
283 else
284 ifeq ($(CONFIG_AUTOFS4_FS),m)
285 MOD_SUB_DIRS += autofs4
286 endif
287 endif
289 ifeq ($(CONFIG_ADFS_FS),y)
290 SUB_DIRS += adfs
291 else
292 ifeq ($(CONFIG_ADFS_FS),m)
293 MOD_SUB_DIRS += adfs
294 endif
295 endif
297 ifeq ($(CONFIG_DEVPTS_FS),y)
298 SUB_DIRS += devpts
299 else
300 ifeq ($(CONFIG_DEVPTS_FS),m)
301 MOD_SUB_DIRS += devpts
302 endif
303 endif
305 ifeq ($(CONFIG_SUN_OPENPROMFS),y)
306 SUB_DIRS += openpromfs
307 else
308 ifeq ($(CONFIG_SUN_OPENPROMFS),m)
309 MOD_SUB_DIRS += openpromfs
310 endif
311 endif
313 ifeq ($(CONFIG_BINFMT_AOUT),y)
314 BINFMTS += binfmt_aout.o
315 else
316 ifeq ($(CONFIG_BINFMT_AOUT),m)
317 M_OBJS += binfmt_aout.o
318 endif
319 endif
321 ifeq ($(CONFIG_BINFMT_EM86),y)
322 BINFMTS += binfmt_em86.o
323 else
324 ifeq ($(CONFIG_BINFMT_EM86),m)
325 M_OBJS += binfmt_em86.o
326 endif
327 endif
329 ifeq ($(CONFIG_BINFMT_MISC),y)
330 BINFMTS += binfmt_misc.o
331 else
332 ifeq ($(CONFIG_BINFMT_MISC),m)
333 M_OBJS += binfmt_misc.o
334 endif
335 endif
337 # binfmt_script is always there
338 BINFMTS += binfmt_script.o
340 ifeq ($(CONFIG_BINFMT_ELF),y)
341 BINFMTS += binfmt_elf.o
342 else
343 ifeq ($(CONFIG_BINFMT_ELF),m)
344 M_OBJS += binfmt_elf.o
345 endif
346 endif
348 include $(TOPDIR)/Rules.make