]> git.ipfire.org Git - thirdparty/e2fsprogs.git/blob - misc/Makefile.in
Add support to build profiled binaries in the misc directory
[thirdparty/e2fsprogs.git] / misc / Makefile.in
1 #
2 # Standard e2fsprogs prologue....
3 #
4
5 srcdir = @srcdir@
6 top_srcdir = @top_srcdir@
7 VPATH = @srcdir@
8 top_builddir = ..
9 my_dir = misc
10 INSTALL = @INSTALL@
11
12 @MCONFIG@
13
14 @IMAGER_CMT@E2IMAGE_PROG= e2image
15 @IMAGER_CMT@E2IMAGE_MAN= e2image.8
16
17 @UUIDD_CMT@UUIDD_PROG= uuidd
18 @UUIDD_CMT@UUIDD_MAN= uuidd.8
19
20 SPROGS= mke2fs badblocks tune2fs dumpe2fs blkid logsave \
21 $(E2IMAGE_PROG) @FSCK_PROG@ e2undo
22 USPROGS= mklost+found filefrag $(UUIDD_PROG)
23 SMANPAGES= tune2fs.8 mklost+found.8 mke2fs.8 dumpe2fs.8 badblocks.8 \
24 e2label.8 findfs.8 blkid.8 $(E2IMAGE_MAN) \
25 logsave.8 filefrag.8 e2undo.8 $(UUIDD_MAN) @FSCK_MAN@
26 FMANPAGES= mke2fs.conf.5
27
28 UPROGS= chattr lsattr uuidgen
29 UMANPAGES= chattr.1 lsattr.1 uuidgen.1
30
31 LPROGS= @E2INITRD_PROG@
32
33 TUNE2FS_OBJS= tune2fs.o util.o
34 MKLPF_OBJS= mklost+found.o
35 MKE2FS_OBJS= mke2fs.o util.o profile.o prof_err.o default_profile.o
36 CHATTR_OBJS= chattr.o
37 LSATTR_OBJS= lsattr.o
38 UUIDGEN_OBJS= uuidgen.o
39 UUIDD_OBJS= uuidd.o
40 DUMPE2FS_OBJS= dumpe2fs.o
41 BADBLOCKS_OBJS= badblocks.o
42 E2IMAGE_OBJS= e2image.o
43 FSCK_OBJS= fsck.o base_device.o ismounted.o
44 BLKID_OBJS= blkid.o
45 FILEFRAG_OBJS= filefrag.o
46 E2UNDO_OBJS= e2undo.o
47
48 PROFILED_TUNE2FS_OBJS= profiled/tune2fs.o profiled/util.o
49 PROFILED_MKLPF_OBJS= profiled/mklost+found.o
50 PROFILED_MKE2FS_OBJS= profiled/mke2fs.o profiled/util.o profiled/profile.o \
51 profiled/prof_err.o profiled/default_profile.o
52 PROFILED_CHATTR_OBJS= profiled/chattr.o
53 PROFILED_LSATTR_OBJS= profiled/lsattr.o
54 PROFILED_UUIDGEN_OBJS= profiled/uuidgen.o
55 PROFILED_UUIDD_OBJS= profiled/uuidd.o
56 PROFILED_DUMPE2FS_OBJS= profiled/dumpe2fs.o
57 PROFILED_BADBLOCKS_OBJS= profiled/badblocks.o
58 PROFILED_E2IMAGE_OBJS= profiled/e2image.o
59 PROFILED_FSCK_OBJS= profiled/fsck.o profiled/base_device.o \
60 profiled/ismounted.o
61 PROFILED_BLKID_OBJS= profiled/blkid.o
62 PROFILED_FILEFRAG_OBJS= profiled/filefrag.o
63 PROFILED_E2UNDO_OBJS= profiled/e2undo.o
64
65
66 XTRA_CFLAGS= -I$(srcdir)/../e2fsck -I.
67
68 SRCS= $(srcdir)/tune2fs.c $(srcdir)/mklost+found.c $(srcdir)/mke2fs.c \
69 $(srcdir)/chattr.c $(srcdir)/lsattr.c $(srcdir)/dumpe2fs.c \
70 $(srcdir)/badblocks.c $(srcdir)/fsck.c $(srcdir)/util.c \
71 $(srcdir)/uuidgen.c $(srcdir)/blkid.c $(srcdir)/logsave.c \
72 $(srcdir)/filefrag.c $(srcdir)/base_device.c \
73 $(srcdir)/ismounted.c $(srcdir)/../e2fsck/profile.c \
74 $(srcdir)/e2undo.c
75
76 LIBS= $(LIBEXT2FS) $(LIBCOM_ERR)
77 DEPLIBS= $(LIBEXT2FS) $(LIBCOM_ERR)
78 PROFILED_LIBS= $(PROFILED_LIBEXT2FS) $(PROFILED_LIBCOM_ERR)
79 PROFILED_DEPLIBS= $(PROFILED_LIBEXT2FS) $(PROFILED_LIBCOM_ERR)
80
81 STATIC_LIBS= $(STATIC_LIBEXT2FS) $(STATIC_LIBCOM_ERR)
82 STATIC_DEPLIBS= $(STATIC_LIBEXT2FS) $(STATIC_LIBCOM_ERR)
83
84 LIBS_E2P= $(LIBE2P) $(LIBCOM_ERR)
85 DEPLIBS_E2P= $(LIBE2P) $(LIBCOM_ERR)
86
87 COMPILE_ET=$(top_builddir)/lib/et/compile_et --build-tree
88
89 .c.o:
90 @echo " CC $<"
91 @$(CC) -c $(ALL_CFLAGS) $< -o $@
92 @PROFILE_CMT@ @$(CC) $(ALL_CFLAGS) -g -pg -o profiled/$*.o -c $<
93
94 all:: profiled $(SPROGS) $(UPROGS) $(USPROGS) $(SMANPAGES) $(UMANPAGES) \
95 $(FMANPAGES) $(LPROGS)
96
97 @PROFILE_CMT@all:: tune2fs.profiled blkid.profiled e2image.profiled \
98 e2undo.profiled mke2fs.profiled dumpe2fs.profiled fsck.profiled \
99 logsave.profiled filefrag.profiled uuidgen.profiled uuidd.profiled \
100 e2image.profiled
101
102 profiled:
103 @PROFILE_CMT@ @echo " MKDIR $@"
104 @PROFILE_CMT@ @mkdir profiled
105
106 prof_err.c prof_err.h: $(srcdir)/../e2fsck/prof_err.et
107 @echo " COMPILE_ET prof_err.et"
108 @$(COMPILE_ET) $(srcdir)/../e2fsck/prof_err.et
109
110 default_profile.c: $(srcdir)/mke2fs.conf $(srcdir)/profile-to-c.awk
111 @echo " PROFILE_TO_C mke2fs.conf"
112 @$(AWK) -f $(srcdir)/profile-to-c.awk < $(srcdir)/mke2fs.conf \
113 > default_profile.c
114 profile.o:
115 @echo " CC $<"
116 @$(CC) -c $(ALL_CFLAGS) $(srcdir)/../e2fsck/profile.c -o $@
117 @PROFILE_CMT@ @$(CC) $(ALL_CFLAGS) -g -pg -o profiled/profile.o -c \
118 @PROFILE_CMT@ $(srcdir)/../e2fsck/profile.c
119
120 findsuper: findsuper.o
121 @echo " LD $@"
122 @$(CC) $(ALL_LDFLAGS) -o findsuper findsuper.o
123
124 partinfo: partinfo.o
125 @echo " LD $@"
126 @$(CC) $(ALL_LDFLAGS) -o partinfo partinfo.o
127
128 e2initrd_helper: e2initrd_helper.o $(DEPLIBS) $(DEPLIBBLKID) $(LIBEXT2FS)
129 @echo " LD $@"
130 @$(CC) $(ALL_LDFLAGS) -o e2initrd_helper e2initrd_helper.o $(LIBS) \
131 $(LIBBLKID) $(LIBEXT2FS) $(LIBINTL)
132
133 tune2fs: $(TUNE2FS_OBJS) $(DEPLIBS) $(DEPLIBS_E2P) $(DEPLIBBLKID) \
134 $(DEPLIBUUID) $(LIBEXT2FS)
135 @echo " LD $@"
136 @$(CC) $(ALL_LDFLAGS) -o tune2fs $(TUNE2FS_OBJS) $(LIBS) \
137 $(LIBBLKID) $(LIBUUID) $(LIBEXT2FS) $(LIBS_E2P) $(LIBINTL)
138
139 tune2fs.static: $(TUNE2FS_OBJS) $(STATIC_DEPLIBS) $(STATIC_LIBE2P) $(DEPSTATIC_LIBBLKID)
140 @echo " LD $@"
141 @$(CC) $(LDFLAGS_STATIC) -o tune2fs.static $(TUNE2FS_OBJS) \
142 $(STATIC_LIBS) $(STATIC_LIBBLKID) $(STATIC_LIBUUID) \
143 $(STATIC_LIBE2P) $(LIBINTL)
144
145 tune2fs.profiled: $(PROFILED_TUNE2FS_OBJS) $(PROFILED_DEPLIBS) \
146 $(PROFILED_E2P) $(DEPPROFILED_LIBBLKID) $(DEPPROFILED_LIBUUID)
147 @echo " LD $@"
148 @$(CC) $(ALL_LDFLAGS) -g -pg -o tune2fs.profiled \
149 $(PROFILED_TUNE2FS_OBJS) $(PROFILED_LIBBLKID) \
150 $(PROFILED_LIBUUID) $(PROFILED_LIBE2P) $(LIBINTL) \
151 $(PROFILED_LIBS)
152
153 blkid: $(BLKID_OBJS) $(DEPLIBBLKID) $(LIBEXT2FS)
154 @echo " LD $@"
155 @$(CC) $(ALL_LDFLAGS) -o blkid $(BLKID_OBJS) $(LIBBLKID) $(LIBINTL) \
156 $(LIBEXT2FS)
157
158 blkid.profiled: $(PROFILED_BLKID_OBJS) $(DEPPROFILED_LIBBLKID) \
159 $(PROFILED_LIBEXT2FS)
160 @echo " LD $@"
161 @$(CC) $(ALL_LDFLAGS) -g -pg -o blkid.profiled $(PROFILED_BLKID_OBJS) \
162 $(PROFILED_LIBBLKID) $(LIBINTL) $(PROFILED_LIBEXT2FS)
163
164 e2image: $(E2IMAGE_OBJS) $(DEPLIBS)
165 @echo " LD $@"
166 @$(CC) $(ALL_LDFLAGS) -o e2image $(E2IMAGE_OBJS) $(LIBS) $(LIBINTL)
167
168 e2image.profiled: $(PROFILED_E2IMAGE_OBJS) $(PROFILED_DEPLIBS)
169 @echo " LD $@"
170 @$(CC) $(ALL_LDFLAGS) -g -pg -o e2image.profiled \
171 $(PROFILED_E2IMAGE_OBJS) $(PROFILED_LIBS) $(LIBINTL)
172
173 e2undo: $(E2UNDO_OBJS) $(DEPLIBS)
174 @echo " LD $@"
175 @$(CC) $(ALL_LDFLAGS) -o e2undo $(E2UNDO_OBJS) $(LIBS) $(LIBINTL)
176
177 e2undo.profiled: $(PROFILED_E2UNDO_OBJS) $(PROFILED_DEPLIBS)
178 @echo " LD $@"
179 @$(CC) $(ALL_LDFLAGS) -g -pg -o e2undo.profiled \
180 $(PROFILED_E2UNDO_OBJS) $(PROFILED_LIBS) $(LIBINTL)
181
182 base_device: base_device.c
183 @echo " LD $@"
184 @$(CC) $(ALL_CFLAGS) $(ALL_LDFLAGS) $(srcdir)/base_device.c \
185 -DDEBUG -o base_device
186
187 check:: base_device
188 ./base_device < $(srcdir)/base_device.tst > base_device.out
189 cmp $(srcdir)/base_device.tst base_device.out
190
191 mklost+found: $(MKLPF_OBJS)
192 @echo " LD $@"
193 @$(CC) $(ALL_LDFLAGS) -o mklost+found $(MKLPF_OBJS) $(LIBINTL)
194
195 mke2fs: $(MKE2FS_OBJS) $(DEPLIBS) $(LIBE2P) $(DEPLIBBLKID) $(DEPLIBUUID) \
196 $(LIBEXT2FS)
197 @echo " LD $@"
198 @$(CC) $(ALL_LDFLAGS) -o mke2fs $(MKE2FS_OBJS) $(LIBS) $(LIBBLKID) \
199 $(LIBUUID) $(LIBEXT2FS) $(LIBE2P) $(LIBINTL)
200
201 mke2fs.static: $(MKE2FS_OBJS) $(STATIC_DEPLIBS) $(STATIC_LIBE2P) $(DEPSTATIC_LIBUUID) $(DEPSTATIC_LIBBLKID)
202 @echo " LD $@"
203 @$(CC) $(ALL_LDFLAGS) -static -o mke2fs.static $(MKE2FS_OBJS) \
204 $(STATIC_LIBS) $(STATIC_LIBE2P) $(STATIC_LIBBLKID) \
205 $(STATIC_LIBUUID) $(LIBINTL)
206
207 mke2fs.profiled: $(PROFILED_MKE2FS_OBJS) $(PROFILED_DEPLIBS) \
208 $(PROFILED_LIBE2P) $(PROFILED_DEPLIBBLKID) $(PROFILED_DEPLIBUUID)
209 @echo " LD $@"
210 @$(CC) $(ALL_LDFLAGS) -g -pg -o mke2fs.profiled \
211 $(PROFILED_MKE2FS_OBJS) $(PROFILED_LIBBLKID) \
212 $(PROFILED_LIBUUID) $(PROFILED_LIBE2P) $(LIBINTL) \
213 $(PROFILED_LIBS)
214
215 chattr: $(CHATTR_OBJS) $(DEPLIBS_E2P)
216 @echo " LD $@"
217 @$(CC) $(ALL_LDFLAGS) -o chattr $(CHATTR_OBJS) $(LIBS_E2P) $(LIBINTL)
218
219 lsattr: $(LSATTR_OBJS) $(DEPLIBS_E2P)
220 @echo " LD $@"
221 @$(CC) $(ALL_LDFLAGS) -o lsattr $(LSATTR_OBJS) $(LIBS_E2P) $(LIBINTL)
222
223 uuidgen: $(UUIDGEN_OBJS) $(DEPLIBUUID)
224 @echo " LD $@"
225 @$(CC) $(ALL_LDFLAGS) -o uuidgen $(UUIDGEN_OBJS) $(LIBUUID) $(LIBINTL)
226
227 uuidgen.profiled: $(PROFILED_UUIDGEN_OBJS) $(PROFILED_DEPLIBUUID)
228 @echo " LD $@"
229 @$(CC) $(ALL_LDFLAGS) -g -pg -o uuidgen.profiled \
230 $(PROFILED_UUIDGEN_OBJS) $(PROFILED_LIBUUID) $(LIBINTL)
231
232 uuidd: $(UUIDD_OBJS) $(DEPLIBUUID)
233 @echo " LD $@"
234 @$(CC) $(ALL_LDFLAGS) -o uuidd $(UUIDD_OBJS) $(LIBUUID) $(LIBINTL)
235
236 uuidd.profiled: $(PROFILED_UUIDD_OBJS) $(PROFILED_DEPLIBUUID)
237 @echo " LD $@"
238 @$(CC) $(ALL_LDFLAGS) -g -pg -o uuidd.profiled $(PROFILED_UUIDD_OBJS) \
239 $(PROFILED_LIBUUID) $(LIBINTL)
240
241 dumpe2fs: $(DUMPE2FS_OBJS) $(DEPLIBS) $(DEPLIBS_E2P) $(DEPLIBUUID)
242 @echo " LD $@"
243 @$(CC) $(ALL_LDFLAGS) -o dumpe2fs $(DUMPE2FS_OBJS) $(LIBS) \
244 $(LIBS_E2P) $(LIBUUID) $(LIBINTL)
245
246 dumpe2fs.profiled: $(PROFILED_DUMPE2FS_OBJS) $(PROFILED_DEPLIBS) \
247 $(PROFILED_LIBE2P) $(PROFILED_DEPLIBUUID)
248 @echo " LD $@"
249 @$(CC) $(ALL_LDFLAGS) -g -pg -o dumpe2fs.profiled \
250 $(PROFILED_DUMPE2FS_OBJS) $(PROFILED_LIBS) \
251 $(PROFILED_LIBE2P) $(PROFILED_LIBUUID) $(LIBINTL)
252
253 fsck: $(FSCK_OBJS) $(DEPLIBBLKID)
254 @echo " LD $@"
255 @$(CC) $(ALL_LDFLAGS) -o fsck $(FSCK_OBJS) $(LIBBLKID) $(LIBINTL)
256
257 fsck.profiled: $(PROFILED_FSCK_OBJS) $(PROFILED_DEPLIBBLKID)
258 @echo " LD $@"
259 @$(CC) $(ALL_LDFLAGS) -g -pg -o fsck.profiled $(PROFILED_FSCK_OBJS) \
260 $(PROFILED_LIBBLKID) $(LIBINTL)
261
262 badblocks: $(BADBLOCKS_OBJS) $(DEPLIBS)
263 @echo " LD $@"
264 @$(CC) $(ALL_LDFLAGS) -o badblocks $(BADBLOCKS_OBJS) $(LIBS) $(LIBINTL)
265
266 badblocks.profiled: $(PROFILED_BADBLOCKS_OBJS) $(PROFILED_DEPLIBS)
267 @echo " LD $@"
268 @$(CC) $(ALL_LDFLAGS) -g -pg -o badblocks.profiled \
269 $(PROFILED_BADBLOCKS_OBJS) $(PROFILED_LIBS) $(LIBINTL)
270
271 logsave: logsave.o
272 @echo " LD $@"
273 @$(CC) $(ALL_LDFLAGS) -o logsave logsave.o
274
275 logsave.profiled: profiled/logsave.o
276 @echo " LD $@"
277 @$(CC) $(ALL_LDFLAGS) -g -pg -o logsave.profiled profiled/logsave.o
278
279 filefrag: $(FILEFRAG_OBJS)
280 @echo " LD $@"
281 @$(CC) $(ALL_LDFLAGS) -o filefrag $(FILEFRAG_OBJS)
282
283 filefrag.profiled: $(PROFILED_FILEFRAG_OBJS)
284 @echo " LD $@"
285 @$(CC) $(ALL_LDFLAGS) -g -pg -o filefrag.profiled \
286 $(PROFILED_FILEFRAG_OBJS)
287
288 tst_ismounted: $(srcdir)/ismounted.c $(STATIC_LIBEXT2FS)
289 @echo " LD $@"
290 $(CC) -o tst_ismounted $(srcdir)/ismounted.c -DDEBUG $(ALL_CFLAGS) $(LIBCOM_ERR)
291
292 tune2fs.8: $(DEP_SUBSTITUTE) $(srcdir)/tune2fs.8.in
293 @echo " SUBST $@"
294 @$(SUBSTITUTE_UPTIME) $(srcdir)/tune2fs.8.in tune2fs.8
295
296 mklost+found.8: $(DEP_SUBSTITUTE) $(srcdir)/mklost+found.8.in
297 @echo " SUBST $@"
298 @$(SUBSTITUTE_UPTIME) $(srcdir)/mklost+found.8.in mklost+found.8
299
300 mke2fs.8: $(DEP_SUBSTITUTE) $(srcdir)/mke2fs.8.in
301 @echo " SUBST $@"
302 @$(SUBSTITUTE_UPTIME) $(srcdir)/mke2fs.8.in mke2fs.8
303
304 mke2fs.conf.5: $(DEP_SUBSTITUTE) $(srcdir)/mke2fs.conf.5.in
305 @echo " SUBST $@"
306 @$(SUBSTITUTE_UPTIME) $(srcdir)/mke2fs.conf.5.in mke2fs.conf.5
307
308 e2label.8: $(DEP_SUBSTITUTE) $(srcdir)/e2label.8.in
309 @echo " SUBST $@"
310 @$(SUBSTITUTE_UPTIME) $(srcdir)/e2label.8.in e2label.8
311
312 e2undo.8: $(DEP_SUBSTITUTE) $(srcdir)/e2undo.8.in
313 @echo " SUBST $@"
314 @$(SUBSTITUTE_UPTIME) $(srcdir)/e2undo.8.in e2undo.8
315
316 findfs.8: $(DEP_SUBSTITUTE) $(srcdir)/findfs.8.in
317 @echo " SUBST $@"
318 @$(SUBSTITUTE_UPTIME) $(srcdir)/findfs.8.in findfs.8
319
320 e2image.8: $(DEP_SUBSTITUTE) $(srcdir)/e2image.8.in
321 @echo " SUBST $@"
322 @$(SUBSTITUTE_UPTIME) $(srcdir)/e2image.8.in e2image.8
323
324 dumpe2fs.8: $(DEP_SUBSTITUTE) $(srcdir)/dumpe2fs.8.in
325 @echo " SUBST $@"
326 @$(SUBSTITUTE_UPTIME) $(srcdir)/dumpe2fs.8.in dumpe2fs.8
327
328 badblocks.8: $(DEP_SUBSTITUTE) $(srcdir)/badblocks.8.in
329 @echo " SUBST $@"
330 @$(SUBSTITUTE_UPTIME) $(srcdir)/badblocks.8.in badblocks.8
331
332 fsck.8: $(DEP_SUBSTITUTE) $(srcdir)/fsck.8.in
333 @echo " SUBST $@"
334 @$(SUBSTITUTE_UPTIME) $(srcdir)/fsck.8.in fsck.8
335
336 blkid.8: $(DEP_SUBSTITUTE) $(srcdir)/blkid.8.in
337 @echo " SUBST $@"
338 @$(SUBSTITUTE_UPTIME) $(srcdir)/blkid.8.in blkid.8
339
340 logsave.8: $(DEP_SUBSTITUTE) $(srcdir)/logsave.8.in
341 @echo " SUBST $@"
342 @$(SUBSTITUTE_UPTIME) $(srcdir)/logsave.8.in logsave.8
343
344 uuidd.8: $(DEP_SUBSTITUTE) $(srcdir)/uuidd.8.in
345 @echo " SUBST $@"
346 @$(SUBSTITUTE_UPTIME) $(srcdir)/uuidd.8.in uuidd.8
347
348 chattr.1: $(DEP_SUBSTITUTE) $(srcdir)/chattr.1.in
349 @echo " SUBST $@"
350 @$(SUBSTITUTE_UPTIME) $(srcdir)/chattr.1.in chattr.1
351
352 lsattr.1: $(DEP_SUBSTITUTE) $(srcdir)/lsattr.1.in
353 @echo " SUBST $@"
354 @$(SUBSTITUTE_UPTIME) $(srcdir)/lsattr.1.in lsattr.1
355
356 uuidgen.1: $(DEP_SUBSTITUTE) $(srcdir)/uuidgen.1.in
357 @echo " SUBST $@"
358 @$(SUBSTITUTE_UPTIME) $(srcdir)/uuidgen.1.in uuidgen.1
359
360 blkid.1: $(DEP_SUBSTITUTE) $(srcdir)/blkid.1.in
361 @echo " SUBST $@"
362 @$(SUBSTITUTE_UPTIME) $(srcdir)/blkid.1.in blkid.1
363
364 filefrag.8: $(DEP_SUBSTITUTE) $(srcdir)/filefrag.8.in
365 @echo " SUBST $@"
366 @$(SUBSTITUTE_UPTIME) $(srcdir)/filefrag.8.in filefrag.8
367
368 installdirs:
369 @echo " MKINSTALLDIRS $(sbindir) $(root_sbindir) $(bindir) $(man1dir) $(man8dir) $(libdir) $(root_sysconfdir)"
370 @$(MKINSTALLDIRS) $(DESTDIR)$(sbindir) \
371 $(DESTDIR)$(root_sbindir) $(DESTDIR)$(bindir) \
372 $(DESTDIR)$(man1dir) $(DESTDIR)$(man8dir) \
373 $(DESTDIR)$(man1dir) $(DESTDIR)$(man5dir) \
374 $(DESTDIR)$(libdir) $(DESTDIR)/$(root_sysconfdir)
375
376 install: all $(SMANPAGES) $(UMANPAGES) installdirs
377 @for i in $(SPROGS); do \
378 echo " INSTALL $(root_sbindir)/$$i"; \
379 $(INSTALL_PROGRAM) $$i $(DESTDIR)$(root_sbindir)/$$i; \
380 done
381 @for i in $(USPROGS); do \
382 echo " INSTALL $(sbindir)/$$i"; \
383 $(INSTALL_PROGRAM) $$i $(DESTDIR)$(sbindir)/$$i; \
384 done
385 @echo " LINK $(root_sbindir)/mkfs.ext2"
386 @$(LN) -f $(DESTDIR)$(root_sbindir)/mke2fs \
387 $(DESTDIR)$(root_sbindir)/mkfs.ext2
388 @echo " LINK $(root_sbindir)/mkfs.ext3"
389 @$(LN) -f $(DESTDIR)$(root_sbindir)/mke2fs \
390 $(DESTDIR)$(root_sbindir)/mkfs.ext3
391 @echo " LINK $(root_sbindir)/mkfs.ext4"
392 @$(LN) -f $(DESTDIR)$(root_sbindir)/mke2fs \
393 $(DESTDIR)$(root_sbindir)/mkfs.ext4
394 @echo " LINK $(root_sbindir)/mkfs.ext4dev"
395 @$(LN) -f $(DESTDIR)$(root_sbindir)/mke2fs \
396 $(DESTDIR)$(root_sbindir)/mkfs.ext4dev
397 @echo " LINK $(root_sbindir)/e2label"
398 @$(LN) -f $(DESTDIR)$(root_sbindir)/tune2fs \
399 $(DESTDIR)$(root_sbindir)/e2label
400 @echo " LINK $(root_sbindir)/findfs"
401 @$(LN) -f $(DESTDIR)$(root_sbindir)/tune2fs \
402 $(DESTDIR)$(root_sbindir)/findfs
403 @for i in $(UPROGS); do \
404 echo " INSTALL $(bindir)/$$i"; \
405 $(INSTALL_PROGRAM) $$i $(DESTDIR)$(bindir)/$$i; \
406 done
407 @for i in $(LPROGS); do \
408 echo " INSTALL $(libdir)/$$i"; \
409 $(INSTALL_PROGRAM) $$i $(DESTDIR)$(libdir)/$$i; \
410 done
411 @for i in $(SMANPAGES); do \
412 for j in $(COMPRESS_EXT); do \
413 $(RM) -f $(DESTDIR)$(man8dir)/$$i.$$j; \
414 done; \
415 echo " INSTALL_DATA $(man8dir)/$$i"; \
416 $(INSTALL_DATA) $$i $(DESTDIR)$(man8dir)/$$i; \
417 done
418 @$(RM) -f $(DESTDIR)$(man8dir)/mkfs.ext2.8.gz \
419 $(DESTDIR)$(man8dir)/mkfs.ext3.8.gz
420 @echo " LINK mkfs.ext2.8"
421 @$(LN) -f $(DESTDIR)$(man8dir)/mke2fs.8 \
422 $(DESTDIR)$(man8dir)/mkfs.ext2.8
423 @echo " LINK mkfs.ext3.8"
424 @$(LN) -f $(DESTDIR)$(man8dir)/mke2fs.8 \
425 $(DESTDIR)$(man8dir)/mkfs.ext3.8
426 @echo " LINK mkfs.ext4.8"
427 @$(LN) -f $(DESTDIR)$(man8dir)/mke2fs.8 \
428 $(DESTDIR)$(man8dir)/mkfs.ext4.8
429 @echo " LINK mkfs.ext4dev.8"
430 @$(LN) -f $(DESTDIR)$(man8dir)/mke2fs.8 \
431 $(DESTDIR)$(man8dir)/mkfs.ext4dev.8
432 @for i in $(UMANPAGES); do \
433 for j in $(COMPRESS_EXT); do \
434 $(RM) -f $(DESTDIR)$(man1dir)/$$i.$$j; \
435 done; \
436 echo " INSTALL_DATA $(man1dir)/$$i"; \
437 $(INSTALL_DATA) $$i $(DESTDIR)$(man1dir)/$$i; \
438 done
439 @for i in $(FMANPAGES); do \
440 for j in $(COMPRESS_EXT); do \
441 $(RM) -f $(DESTDIR)$(man5dir)/$$i.$$j; \
442 done; \
443 echo " INSTALL_DATA $(man5dir)/$$i"; \
444 $(INSTALL_DATA) $$i $(DESTDIR)$(man5dir)/$$i; \
445 done
446 @if test -f $(DESTDIR)$(root_sysconfdir)/mke2fs.conf; then \
447 if cmp -s $(DESTDIR)$(root_sysconfdir)/mke2fs.conf \
448 $(srcdir)/mke2fs.conf; then \
449 true; \
450 else \
451 if grep -q ext4dev $(DESTDIR)$(root_sysconfdir)/mke2fs.conf ; then \
452 echo " INSTALL_DATA $(root_sysconfdir)/mke2fs.conf.e2fsprogs-new"; \
453 $(INSTALL_DATA) $(srcdir)/mke2fs.conf \
454 $(DESTDIR)$(root_sysconfdir)/mke2fs.conf.e2fsprogs-new; \
455 echo "Warning: installing mke2fs.conf in $(DESTDIR)$(root_sysconfdir)/mke2fs.conf.e2fsprogs-new"; \
456 echo "Check to see if you need to update your $(root_sysconfdir)/mke2fs.conf"; \
457 else \
458 echo " INSTALL_DATA $(root_sysconfdir)/mke2fs.conf"; \
459 mv $(DESTDIR)$(root_sysconfdir)/mke2fs.conf \
460 $(DESTDIR)$(root_sysconfdir)/mke2fs.conf.e2fsprogs-old; \
461 $(INSTALL_DATA) $(srcdir)/mke2fs.conf \
462 $(DESTDIR)$(root_sysconfdir)/mke2fs.conf; \
463 echo "Your mke2fs.conf is too old. Backing up old version in"; \
464 echo "$(DESTDIR)$(root_sysconfdir)/mke2fs.conf.e2fsprogs-old. Please check to see"; \
465 echo "if you have any local customizations that you wish to preserve."; \
466 fi; \
467 echo " "; \
468 fi; \
469 else \
470 echo " INSTALL_DATA $(root_sysconfdir)/mke2fs.conf"; \
471 $(INSTALL_DATA) $(srcdir)/mke2fs.conf \
472 $(DESTDIR)$(root_sysconfdir)/mke2fs.conf; \
473 fi
474
475 install-strip: install
476 @for i in $(SPROGS); do \
477 echo " STRIP $(root_sbindir)/$$i"; \
478 $(STRIP) $(DESTDIR)$(root_sbindir)/$$i; \
479 done
480 @for i in $(USPROGS); do \
481 echo " STRIP $(sbindir)/$$i"; \
482 $(STRIP) $(DESTDIR)$(sbindir)/$$i; \
483 done
484
485 uninstall:
486 for i in $(SPROGS); do \
487 $(RM) -f $(DESTDIR)$(root_sbindir)/$$i; \
488 done
489 for i in $(USPROGS); do \
490 $(RM) -f $(DESTDIR)$(sbindir)/$$i; \
491 done
492 for i in $(LPROGS); do \
493 $(RM) -f $(DESTDIR)$(libdir)/$$i; \
494 done
495 $(RM) -f $(DESTDIR)$(root_sbindir)/mkfs.ext2 \
496 $(DESTDIR)$(root_sbindir)/mkfs.ext3 \
497 $(DESTDIR)$(root_sbindir)/mkfs.ext4 \
498 $(DESTDIR)$(root_sbindir)/mkfs.ext4dev
499 for i in $(UPROGS); do \
500 $(RM) -f $(DESTDIR)$(bindir)/$$i; \
501 done
502 for i in $(SMANPAGES); do \
503 $(RM) -f $(DESTDIR)$(man8dir)/$$i; \
504 done
505 $(RM) -f $(DESTDIR)$(man8dir)/mkfs.ext2.8 \
506 $(DESTDIR)$(man8dir)/mkfs.ext3.8 \
507 $(DESTDIR)$(man8dir)/mkfs.ext4.8 \
508 $(DESTDIR)$(man8dir)/mkfs.ext4dev.8
509 for i in $(UMANPAGES); do \
510 $(RM) -f $(DESTDIR)$(man1dir)/$$i; \
511 done
512 for i in findfs e2label ; do \
513 $(RM) -f $(DESTDIR)$(root_sbindir)/$$i; \
514 done
515 for i in $(FMANPAGES); do \
516 $(RM) -f $(DESTDIR)$(man5dir)/$$i; \
517 done
518 if cmp -s $(srcdir)/mke2fs.conf $(DESTDIR)/$(root_sysconfdir)/mke2fs.conf; then \
519 $(RM) $(DESTDIR)/$(root_sysconfdir)/mke2fs.conf; \
520 fi
521
522 clean:
523 $(RM) -f $(SPROGS) $(USPROGS) $(UPROGS) $(UMANPAGES) $(SMANPAGES) \
524 $(FMANPAGES) \
525 base_device base_device.out mke2fs.static filefrag \
526 e2initrd_helper partinfo prof_err.[ch] default_profile.c \
527 uuidd e2image tune2fs.static tst_ismounted fsck.profiled \
528 blkid.profiled tune2fs.profiled e2image.profiled \
529 e2undo.profiled mke2fs.profiled dumpe2fs.profiled \
530 logsave.profiled filefrag.profiled uuidgen.profiled \
531 uuidd.profiled e2image.profiled \
532 profiled/*.o \#* *.s *.o *.a *~ core gmon.out
533
534 mostlyclean: clean
535 distclean: clean
536 $(RM) -f .depend Makefile $(srcdir)/TAGS $(srcdir)/Makefile.in.old
537
538 # +++ Dependency line eater +++
539 #
540 # Makefile dependencies follow. This must be the last section in
541 # the Makefile.in file
542 #
543 tune2fs.o: $(srcdir)/tune2fs.c $(top_srcdir)/lib/ext2fs/ext2_fs.h \
544 $(top_builddir)/lib/ext2fs/ext2_types.h $(top_srcdir)/lib/ext2fs/ext2fs.h \
545 $(top_srcdir)/lib/ext2fs/ext2_fs.h $(top_srcdir)/lib/ext2fs/ext3_extents.h \
546 $(top_srcdir)/lib/et/com_err.h $(top_srcdir)/lib/ext2fs/ext2_io.h \
547 $(top_builddir)/lib/ext2fs/ext2_err.h $(top_srcdir)/lib/ext2fs/bitops.h \
548 $(top_srcdir)/lib/uuid/uuid.h $(top_srcdir)/lib/e2p/e2p.h \
549 $(srcdir)/jfs_user.h $(top_srcdir)/lib/ext2fs/kernel-jbd.h \
550 $(top_srcdir)/lib/ext2fs/jfs_compat.h $(top_srcdir)/lib/ext2fs/kernel-list.h \
551 $(srcdir)/util.h $(top_srcdir)/lib/blkid/blkid.h \
552 $(top_builddir)/lib/blkid/blkid_types.h $(top_srcdir)/version.h \
553 $(srcdir)/nls-enable.h
554 mklost+found.o: $(srcdir)/mklost+found.c $(top_srcdir)/lib/ext2fs/ext2_fs.h \
555 $(top_builddir)/lib/ext2fs/ext2_types.h $(top_srcdir)/version.h \
556 $(srcdir)/nls-enable.h
557 mke2fs.o: $(srcdir)/mke2fs.c $(top_srcdir)/lib/ext2fs/ext2_fs.h \
558 $(top_builddir)/lib/ext2fs/ext2_types.h $(top_srcdir)/lib/et/com_err.h \
559 $(top_srcdir)/lib/uuid/uuid.h $(top_srcdir)/lib/e2p/e2p.h \
560 $(top_srcdir)/lib/ext2fs/ext2_fs.h $(top_srcdir)/lib/ext2fs/ext2fs.h \
561 $(top_srcdir)/lib/ext2fs/ext3_extents.h $(top_srcdir)/lib/et/com_err.h \
562 $(top_srcdir)/lib/ext2fs/ext2_io.h $(top_builddir)/lib/ext2fs/ext2_err.h \
563 $(top_srcdir)/lib/ext2fs/bitops.h $(srcdir)/util.h \
564 $(srcdir)/../e2fsck/profile.h prof_err.h $(top_srcdir)/version.h \
565 $(srcdir)/nls-enable.h
566 chattr.o: $(srcdir)/chattr.c $(top_srcdir)/lib/ext2fs/ext2_fs.h \
567 $(top_builddir)/lib/ext2fs/ext2_types.h $(top_srcdir)/lib/et/com_err.h \
568 $(top_srcdir)/lib/e2p/e2p.h $(top_srcdir)/lib/ext2fs/ext2_fs.h \
569 $(top_srcdir)/version.h $(srcdir)/nls-enable.h
570 lsattr.o: $(srcdir)/lsattr.c $(top_srcdir)/lib/ext2fs/ext2_fs.h \
571 $(top_builddir)/lib/ext2fs/ext2_types.h $(top_srcdir)/lib/et/com_err.h \
572 $(top_srcdir)/lib/e2p/e2p.h $(top_srcdir)/lib/ext2fs/ext2_fs.h \
573 $(top_srcdir)/version.h $(srcdir)/nls-enable.h
574 dumpe2fs.o: $(srcdir)/dumpe2fs.c $(top_srcdir)/lib/ext2fs/ext2_fs.h \
575 $(top_builddir)/lib/ext2fs/ext2_types.h $(top_srcdir)/lib/ext2fs/ext2fs.h \
576 $(top_srcdir)/lib/ext2fs/ext2_fs.h $(top_srcdir)/lib/ext2fs/ext3_extents.h \
577 $(top_srcdir)/lib/et/com_err.h $(top_srcdir)/lib/ext2fs/ext2_io.h \
578 $(top_builddir)/lib/ext2fs/ext2_err.h $(top_srcdir)/lib/ext2fs/bitops.h \
579 $(top_srcdir)/lib/e2p/e2p.h $(srcdir)/jfs_user.h \
580 $(top_srcdir)/lib/ext2fs/kernel-jbd.h $(top_srcdir)/lib/ext2fs/jfs_compat.h \
581 $(top_srcdir)/lib/ext2fs/kernel-list.h $(top_srcdir)/lib/uuid/uuid.h \
582 $(top_srcdir)/version.h $(srcdir)/nls-enable.h
583 badblocks.o: $(srcdir)/badblocks.c $(top_srcdir)/lib/et/com_err.h \
584 $(top_srcdir)/lib/ext2fs/ext2_io.h $(top_srcdir)/lib/ext2fs/ext2_fs.h \
585 $(top_builddir)/lib/ext2fs/ext2_types.h $(top_srcdir)/lib/ext2fs/ext2fs.h \
586 $(top_srcdir)/lib/ext2fs/ext2_fs.h $(top_srcdir)/lib/ext2fs/ext3_extents.h \
587 $(top_srcdir)/lib/et/com_err.h $(top_srcdir)/lib/ext2fs/ext2_io.h \
588 $(top_builddir)/lib/ext2fs/ext2_err.h $(top_srcdir)/lib/ext2fs/bitops.h \
589 $(srcdir)/nls-enable.h
590 fsck.o: $(srcdir)/fsck.c $(top_srcdir)/version.h $(srcdir)/nls-enable.h \
591 $(srcdir)/fsck.h $(top_srcdir)/lib/blkid/blkid.h \
592 $(top_builddir)/lib/blkid/blkid_types.h
593 util.o: $(srcdir)/util.c $(top_srcdir)/lib/et/com_err.h \
594 $(top_srcdir)/lib/e2p/e2p.h $(top_srcdir)/lib/ext2fs/ext2_fs.h \
595 $(top_builddir)/lib/ext2fs/ext2_types.h $(top_srcdir)/lib/ext2fs/ext2fs.h \
596 $(top_srcdir)/lib/ext2fs/ext3_extents.h $(top_srcdir)/lib/et/com_err.h \
597 $(top_srcdir)/lib/ext2fs/ext2_io.h $(top_builddir)/lib/ext2fs/ext2_err.h \
598 $(top_srcdir)/lib/ext2fs/bitops.h $(srcdir)/nls-enable.h \
599 $(top_srcdir)/lib/blkid/blkid.h $(top_builddir)/lib/blkid/blkid_types.h \
600 $(srcdir)/util.h
601 uuidgen.o: $(srcdir)/uuidgen.c $(top_srcdir)/lib/uuid/uuid.h \
602 $(srcdir)/nls-enable.h
603 blkid.o: $(srcdir)/blkid.c $(top_srcdir)/lib/blkid/blkid.h \
604 $(top_builddir)/lib/blkid/blkid_types.h
605 logsave.o: $(srcdir)/logsave.c
606 filefrag.o: $(srcdir)/filefrag.c
607 base_device.o: $(srcdir)/base_device.c $(srcdir)/fsck.h
608 ismounted.o: $(srcdir)/ismounted.c $(top_srcdir)/lib/et/com_err.h
609 profile.o: $(srcdir)/../e2fsck/profile.c $(top_srcdir)/lib/et/com_err.h \
610 $(srcdir)/../e2fsck/profile.h prof_err.h
611 e2undo.o: $(srcdir)/e2undo.c $(top_srcdir)/lib/ext2fs/tdb.h