]> git.ipfire.org Git - thirdparty/e2fsprogs.git/blame - misc/Makefile.in
Many files:
[thirdparty/e2fsprogs.git] / misc / Makefile.in
CommitLineData
a418d3ad
TT
1#
2# Standard e2fsprogs prologue....
3#
4
5srcdir = @srcdir@
6top_srcdir = @top_srcdir@
7VPATH = @srcdir@
8top_builddir = ..
1e3472c5 9my_dir = misc
a418d3ad
TT
10INSTALL = @INSTALL@
11
12@MCONFIG@
13
83238153 14SPROGS= mke2fs badblocks tune2fs dumpe2fs e2image @FSCK_PROG@
a418d3ad 15USPROGS= mklost+found
1e3472c5 16SMANPAGES= tune2fs.8 mklost+found.8 mke2fs.8 dumpe2fs.8 badblocks.8 \
348e43dc 17 e2label.8 e2image.8 @FSCK_MAN@
a418d3ad 18
5d45d803
TT
19UPROGS= chattr lsattr uuidgen
20UMANPAGES= chattr.1 lsattr.1 uuidgen.1
a418d3ad 21
63985320 22TUNE2FS_OBJS= tune2fs.o util.o
a418d3ad 23MKLPF_OBJS= mklost+found.o
63985320 24MKE2FS_OBJS= mke2fs.o util.o
a418d3ad
TT
25CHATTR_OBJS= chattr.o
26LSATTR_OBJS= lsattr.o
5d45d803 27UUIDGEN_OBJS= uuidgen.o
a418d3ad
TT
28DUMPE2FS_OBJS= dumpe2fs.o
29BADBLOCKS_OBJS= badblocks.o
72ed1264 30E2IMAGE_OBJS= e2image.o
793e27df 31FSCK_OBJS= fsck.o get_device_by_label.o base_device.o
a418d3ad
TT
32
33SRCS= $(srcdir)/tune2fs.c $(srcdir)/mklost+found.c $(srcdir)/mke2fs.c \
34 $(srcdir)/chattr.c $(srcdir)/lsattr.c $(srcdir)/dumpe2fs.c \
63985320
TT
35 $(srcdir)/badblocks.c $(srcdir)/fsck.c $(srcdir)/util.c \
36 $(srcdir)/uuidgen.c
a418d3ad 37
62c06f79
TT
38LIBS= $(LIBEXT2FS) $(LIBCOM_ERR)
39DEPLIBS= $(LIBEXT2FS) $(LIBCOM_ERR)
40
41STATIC_LIBS= $(STATIC_LIBEXT2FS) $(STATIC_LIBCOM_ERR)
42STATIC_DEPLIBS= $(STATIC_LIBEXT2FS) $(STATIC_LIBCOM_ERR)
43
44LIBS_E2P= $(LIBEXT2FS) $(LIBE2P) $(LIBCOM_ERR)
45DEPLIBS_E2P= $(LIBEXT2FS) $(LIBE2P) $(LIBCOM_ERR)
a418d3ad
TT
46
47.c.o:
74becf3c 48 $(CC) -c $(ALL_CFLAGS) $< -o $@
a418d3ad 49
44339bdf 50all:: $(SPROGS) $(UPROGS) $(USPROGS) $(SMANPAGES) $(UMANPAGES)
a418d3ad 51
b89122fc
TT
52findsuper: findsuper.o
53 $(CC) $(ALL_LDFLAGS) -o findsuper findsuper.o
54
3cb7784f 55tune2fs: $(TUNE2FS_OBJS) $(DEPLIBS_E2P) $(DEPLIBUUID)
1e3472c5 56 $(CC) $(ALL_LDFLAGS) -o tune2fs $(TUNE2FS_OBJS) $(LIBS_E2P) $(LIBUUID)
a418d3ad 57
72ed1264
TT
58e2image: $(E2IMAGE_OBJS) $(DEPLIBS)
59 $(CC) $(ALL_LDFLAGS) -o e2image $(E2IMAGE_OBJS) $(LIBS)
60
793e27df
TT
61base_device: base_device.c
62 $(CC) $(ALL_CFLAGS) $(ALL_LDFLAGS) $< -DDEBUG -o $@
63
64check:: base_device
65 ./base_device < $(srcdir)/base_device.tst > base_device.out
66 cmp $(srcdir)/base_device.tst base_device.out
67
a418d3ad 68mklost+found: $(MKLPF_OBJS)
74becf3c 69 $(CC) $(ALL_LDFLAGS) -o mklost+found $(MKLPF_OBJS)
a418d3ad 70
3cb7784f 71mke2fs: $(MKE2FS_OBJS) $(DEPLIBS) $(LIBE2P) $(DEPLIBUUID)
896938d5 72 $(CC) $(ALL_LDFLAGS) -o mke2fs $(MKE2FS_OBJS) $(LIBS) $(LIBE2P) $(LIBUUID)
a418d3ad 73
3cb7784f 74mke2fs.static: $(MKE2FS_OBJS) $(STATIC_DEPLIBS) $(STATIC_LIBE2P) $(DEPSTATIC_LIBUUID)
62c06f79 75 $(CC) $(ALL_LDFLAGS) -static -o mke2fs.static $(MKE2FS_OBJS) \
896938d5 76 $(STATIC_LIBS) $(STATIC_LIBE2P) $(STATIC_LIBUUID)
1e3472c5
TT
77
78resize2fs: resize2fs.o $(DEPLIBS)
79 $(CC) $(ALL_LDFLAGS) -o resize2fs resize2fs.o $(LIBS)
a418d3ad 80
62c06f79
TT
81chattr: $(CHATTR_OBJS) $(DEPLIBS_E2P)
82 $(CC) $(ALL_LDFLAGS) -o chattr $(CHATTR_OBJS) $(LIBS_E2P)
a418d3ad 83
62c06f79
TT
84lsattr: $(LSATTR_OBJS) $(DEPLIBS_E2P)
85 $(CC) $(ALL_LDFLAGS) -o lsattr $(LSATTR_OBJS) $(LIBS_E2P)
a418d3ad 86
3cb7784f 87uuidgen: $(UUIDGEN_OBJS) $(DEPLIBUUID)
5d45d803
TT
88 $(CC) $(ALL_LDFLAGS) -o uuidgen $(UUIDGEN_OBJS) $(LIBUUID)
89
16ed5b3a
TT
90dumpe2fs: $(DUMPE2FS_OBJS) $(DEPLIBS_E2P) $(DEPLIBUUID)
91 $(CC) $(ALL_LDFLAGS) -o dumpe2fs $(DUMPE2FS_OBJS) $(LIBS_E2P) $(LIBUUID)
a418d3ad 92
62c06f79 93fsck: $(FSCK_OBJS)
556ccbd6 94 $(CC) $(ALL_LDFLAGS) -o fsck $(FSCK_OBJS) $(LIBS)
a418d3ad
TT
95
96badblocks: $(BADBLOCKS_OBJS) $(DEPLIBS)
74becf3c 97 $(CC) $(ALL_LDFLAGS) -o badblocks $(BADBLOCKS_OBJS) $(LIBS)
a418d3ad 98
44339bdf 99tune2fs.8: $(DEP_SUBSTITUTE) $(srcdir)/tune2fs.8.in
62c06f79
TT
100 $(SUBSTITUTE) $(srcdir)/tune2fs.8.in tune2fs.8
101
44339bdf 102mklost+found.8: $(DEP_SUBSTITUTE) $(srcdir)/mklost+found.8.in
62c06f79
TT
103 $(SUBSTITUTE) $(srcdir)/mklost+found.8.in mklost+found.8
104
44339bdf 105mke2fs.8: $(DEP_SUBSTITUTE) $(srcdir)/mke2fs.8.in
62c06f79
TT
106 $(SUBSTITUTE) $(srcdir)/mke2fs.8.in mke2fs.8
107
a789d840
TT
108e2label.8: $(DEP_SUBSTITUTE) $(srcdir)/e2label.8.in
109 $(SUBSTITUTE) $(srcdir)/e2label.8.in e2label.8
110
348e43dc
TT
111e2image.8: $(DEP_SUBSTITUTE) $(srcdir)/e2image.8.in
112 $(SUBSTITUTE) $(srcdir)/e2image.8.in e2image.8
113
44339bdf 114dumpe2fs.8: $(DEP_SUBSTITUTE) $(srcdir)/dumpe2fs.8.in
62c06f79
TT
115 $(SUBSTITUTE) $(srcdir)/dumpe2fs.8.in dumpe2fs.8
116
44339bdf 117badblocks.8: $(DEP_SUBSTITUTE) $(srcdir)/badblocks.8.in
62c06f79
TT
118 $(SUBSTITUTE) $(srcdir)/badblocks.8.in badblocks.8
119
44339bdf 120fsck.8: $(DEP_SUBSTITUTE) $(srcdir)/fsck.8.in
62c06f79
TT
121 $(SUBSTITUTE) $(srcdir)/fsck.8.in fsck.8
122
44339bdf 123chattr.1: $(DEP_SUBSTITUTE) $(srcdir)/chattr.1.in
62c06f79
TT
124 $(SUBSTITUTE) $(srcdir)/chattr.1.in chattr.1
125
44339bdf 126lsattr.1: $(DEP_SUBSTITUTE) $(srcdir)/lsattr.1.in
62c06f79
TT
127 $(SUBSTITUTE) $(srcdir)/lsattr.1.in lsattr.1
128
5d45d803
TT
129uuidgen.1: $(DEP_SUBSTITUTE) $(srcdir)/uuidgen.1.in
130 $(SUBSTITUTE) $(srcdir)/uuidgen.1.in uuidgen.1
131
a418d3ad 132installdirs:
7e44f242
TT
133 $(top_srcdir)/mkinstalldirs $(DESTDIR)$(sbindir) \
134 $(DESTDIR)$(root_sbindir) $(DESTDIR)$(bindir) \
135 $(DESTDIR)$(man1dir) $(DESTDIR)$(man8dir)
a418d3ad
TT
136
137install: all $(SMANPAGES) $(UMANPAGES) installdirs
138 for i in $(SPROGS); do \
7e44f242
TT
139 $(INSTALL_PROGRAM) $$i $(DESTDIR)$(root_sbindir)/$$i; \
140 $(STRIP) $(DESTDIR)$(root_sbindir)/$$i; \
a418d3ad
TT
141 done
142 for i in $(USPROGS); do \
7e44f242
TT
143 $(INSTALL_PROGRAM) $$i $(DESTDIR)$(sbindir)/$$i; \
144 $(STRIP) $(DESTDIR)$(sbindir)/$$i; \
a418d3ad 145 done
7e44f242
TT
146 $(LN) -f $(DESTDIR)$(root_sbindir)/mke2fs \
147 $(DESTDIR)$(root_sbindir)/mkfs.ext2
83238153
TT
148 $(LN) -f $(DESTDIR)$(root_sbindir)/tune2fs \
149 $(DESTDIR)$(root_sbindir)/e2label
a418d3ad 150 for i in $(UPROGS); do \
7e44f242
TT
151 $(INSTALL_PROGRAM) $$i $(DESTDIR)$(bindir)/$$i; \
152 $(STRIP) $(DESTDIR)$(bindir)/$$i; \
a418d3ad
TT
153 done
154 for i in $(SMANPAGES); do \
74becf3c 155 $(INSTALL_DATA) $$i $(DESTDIR)$(man8dir)/$$i; \
a418d3ad
TT
156 done
157 for i in $(UMANPAGES); do \
74becf3c 158 $(INSTALL_DATA) $$i $(DESTDIR)$(man1dir)/$$i; \
a418d3ad
TT
159 done
160
161uninstall:
162 for i in $(SPROGS); do \
7e44f242 163 $(RM) -f $(DESTDIR)$(root_sbindir)/$$i; \
a418d3ad
TT
164 done
165 for i in $(USPROGS); do \
7e44f242 166 $(RM) -f $(DESTDIR)$(sbindir)/$$i; \
a418d3ad 167 done
7e44f242 168 $(RM) -f $(DESTDIR)$(root_sbindir)/mkfs.ext2
a418d3ad 169 for i in $(UPROGS); do \
7e44f242 170 $(RM) -f $(DESTDIR)$(bindir)/$$i; \
a418d3ad
TT
171 done
172 for i in $(SMANPAGES); do \
7e44f242 173 $(RM) -f $(DESTDIR)$(man8dir)/$$i; \
a418d3ad
TT
174 done
175 for i in $(UMANPAGES); do \
7e44f242 176 $(RM) -f $(DESTDIR)$(man1dir)/$$i; \
a418d3ad
TT
177 done
178
179clean:
62c06f79 180 $(RM) -f $(SPROGS) $(USPROGS) $(UPROGS) $(UMANPAGES) $(SMANPAGES) \
793e27df
TT
181 base_device base_device.out mke2fs.static \
182 \#* *.s *.o *.a *~ core
62c06f79 183
a418d3ad
TT
184mostlyclean: clean
185distclean: clean
5c36a2f8 186 $(RM) -f .depend Makefile $(srcdir)/TAGS $(srcdir)/Makefile.in.old
a418d3ad
TT
187
188# +++ Dependency line eater +++
189#
190# Makefile dependencies follow. This must be the last section in
191# the Makefile.in file
192#
54c637d4 193tune2fs.o: $(srcdir)/tune2fs.c $(top_srcdir)/lib/ext2fs/ext2_fs.h \
0e8a9560
TT
194 $(top_srcdir)/lib/ext2fs/ext2fs.h $(top_srcdir)/lib/et/com_err.h \
195 $(top_srcdir)/lib/ext2fs/ext2_io.h $(top_builddir)/lib/ext2fs/ext2_err.h \
196 $(top_srcdir)/lib/ext2fs/bitops.h $(top_srcdir)/lib/uuid/uuid.h \
a05c589a
TT
197 $(top_srcdir)/lib/e2p/e2p.h $(srcdir)/jfs_user.h \
198 $(top_srcdir)/include/linux/jfs.h $(top_srcdir)/include/linux/jfs_compat.h \
54c637d4 199 $(top_srcdir)/include/linux/list.h $(srcdir)/util.h $(top_srcdir)/version.h \
63985320 200 $(srcdir)/nls-enable.h
54c637d4
TT
201mklost+found.o: $(srcdir)/mklost+found.c $(top_srcdir)/lib/ext2fs/ext2_fs.h \
202 $(top_srcdir)/version.h $(srcdir)/nls-enable.h
203mke2fs.o: $(srcdir)/mke2fs.c $(top_srcdir)/lib/ext2fs/ext2_fs.h \
0e8a9560
TT
204 $(top_srcdir)/lib/et/com_err.h $(top_srcdir)/lib/uuid/uuid.h \
205 $(top_srcdir)/lib/e2p/e2p.h $(top_srcdir)/lib/ext2fs/ext2fs.h \
206 $(top_srcdir)/lib/ext2fs/ext2_io.h $(top_builddir)/lib/ext2fs/ext2_err.h \
54c637d4 207 $(top_srcdir)/lib/ext2fs/bitops.h $(srcdir)/util.h $(top_srcdir)/version.h \
0e8a9560 208 $(srcdir)/nls-enable.h
54c637d4 209chattr.o: $(srcdir)/chattr.c $(top_srcdir)/lib/ext2fs/ext2_fs.h \
0e8a9560 210 $(top_srcdir)/lib/et/com_err.h $(top_srcdir)/lib/e2p/e2p.h \
54c637d4
TT
211 $(top_srcdir)/version.h $(srcdir)/nls-enable.h
212lsattr.o: $(srcdir)/lsattr.c $(top_srcdir)/lib/ext2fs/ext2_fs.h \
0e8a9560 213 $(top_srcdir)/lib/et/com_err.h $(top_srcdir)/lib/e2p/e2p.h \
54c637d4
TT
214 $(top_srcdir)/version.h $(srcdir)/nls-enable.h
215dumpe2fs.o: $(srcdir)/dumpe2fs.c $(top_srcdir)/lib/ext2fs/ext2_fs.h \
0e8a9560
TT
216 $(top_srcdir)/lib/ext2fs/ext2fs.h $(top_srcdir)/lib/et/com_err.h \
217 $(top_srcdir)/lib/ext2fs/ext2_io.h $(top_builddir)/lib/ext2fs/ext2_err.h \
218 $(top_srcdir)/lib/ext2fs/bitops.h $(top_srcdir)/lib/e2p/e2p.h \
a05c589a
TT
219 $(srcdir)/jfs_user.h $(top_srcdir)/include/linux/jfs.h \
220 $(top_srcdir)/include/linux/jfs_compat.h $(top_srcdir)/include/linux/list.h \
54c637d4 221 $(top_srcdir)/version.h $(srcdir)/nls-enable.h
62c06f79 222badblocks.o: $(srcdir)/badblocks.c $(top_srcdir)/lib/et/com_err.h \
54c637d4 223 $(top_srcdir)/lib/ext2fs/ext2_io.h $(top_srcdir)/lib/ext2fs/ext2_fs.h \
0e8a9560
TT
224 $(top_srcdir)/lib/ext2fs/ext2fs.h $(top_builddir)/lib/ext2fs/ext2_err.h \
225 $(top_srcdir)/lib/ext2fs/bitops.h $(srcdir)/nls-enable.h
54c637d4 226fsck.o: $(srcdir)/fsck.c $(top_srcdir)/version.h $(srcdir)/nls-enable.h \
0e8a9560 227 $(srcdir)/fsck.h $(srcdir)/get_device_by_label.h
54c637d4
TT
228util.o: $(srcdir)/util.c $(top_srcdir)/lib/et/com_err.h \
229 $(top_srcdir)/lib/e2p/e2p.h $(top_srcdir)/lib/ext2fs/ext2_fs.h \
63985320
TT
230 $(top_srcdir)/lib/ext2fs/ext2fs.h $(top_srcdir)/lib/ext2fs/ext2_io.h \
231 $(top_builddir)/lib/ext2fs/ext2_err.h $(top_srcdir)/lib/ext2fs/bitops.h \
232 $(srcdir)/nls-enable.h $(srcdir)/util.h
0e8a9560
TT
233uuidgen.o: $(srcdir)/uuidgen.c $(top_srcdir)/lib/uuid/uuid.h \
234 $(srcdir)/nls-enable.h