• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1#
2# Standard e2fsprogs prologue....
3#
4
5srcdir = @srcdir@
6top_srcdir = @top_srcdir@
7VPATH = @srcdir@
8top_builddir = ..
9my_dir = ext2ed
10INSTALL = @INSTALL@
11MKDIR_P = @MKDIR_P@
12
13@MCONFIG@
14
15PROGS=		ext2ed
16MANPAGES=	ext2ed.8
17
18DOC_DIR		=	$datadir/doc/ext2ed
19
20LIBS		=	-lncurses $(LIBEXT2FS)
21
22SRCS=	$(srcdir)/main.c $(srcdir)/init.c $(srcdir)/general_com.c       \
23	$(srcdir)/inode_com.c $(srcdir)/dir_com.c $(srcdir)/super_com.c \
24	$(srcdir)/disk.c $(srcdir)/win.c $(srcdir)/group_com.c          \
25	$(srcdir)/file_com.c $(srcdir)/blockbitmap_com.c                \
26	$(srcdir)/ext2_com.c $(srcdir)/inodebitmap_com.c
27
28OBJS=	main.o init.o general_com.o inode_com.o dir_com.o super_com.o    \
29	disk.o win.o group_com.o file_com.o blockbitmap_com.o ext2_com.o \
30	inodebitmap_com.o
31
32DOCS=   doc/ext2ed-design.pdf doc/user-guide.pdf doc/ext2fs-overview.pdf \
33	doc/ext2ed-design.html doc/user-guide.html doc/ext2fs-overview.html
34
35.c.o:
36	$(CC) -c $(ALL_CFLAGS) $< -o $@
37	$(CHECK_CMD) $(ALL_CFLAGS) $<
38	$(CPPCHECK_CMD) $(CPPFLAGS) $<
39
40.SUFFIXES: .sgml .ps .pdf .html
41
42.sgml.ps:
43	mkdir -p doc
44	sgmltools -b ps $<
45	-mv `echo $< | sed -e 's/.sgml$$/.ps/'` $@
46
47.sgml.pdf:
48	mkdir -p doc
49	sgmltools -b pdf $<
50	-mv `echo $< | sed -e 's/.sgml$$/.pdf/'` $@
51
52.sgml.html:
53	mkdir -p doc
54	sgmltools -b onehtml $<
55	-mv `echo $< | sed -e 's/.sgml$$/.html/'` $@
56
57all:: $(PROGS) $(MANPAGES) ext2ed.conf
58
59docs: $(DOCS)
60
61ext2ed: $(OBJS)
62	$(CC) $(ALL_LDFLAGS) -o ext2ed $(OBJS) $(LIBS)
63
64ext2ed.8: $(DEP_SUBSTITUTE) $(srcdir)/ext2ed.8.in
65	$(SUBSTITUTE_UPTIME) $(srcdir)/ext2ed.8.in ext2ed.8
66
67ext2ed.conf: $(DEP_SUBSTITUTE) $(srcdir)/ext2ed.conf.in
68	$(SUBSTITUTE_UPTIME) $(srcdir)/ext2ed.conf.in ext2ed.conf
69
70clean::
71	$(RM) -f ext2ed $(OBJS) $(DOCS) ext2ed.conf ext2ed.8
72	-rmdir doc
73
74install: ext2ed
75	install -d $(root_sysconfdir)
76	install -m 755 ext2ed $(sbindir)
77	install -m 644 $(srcdir)/ext2.descriptors $(datadir)
78	install -m 644 ext2ed.conf $(root_sysconfdir)
79	install -m 644 ext2ed.8 $(man8dir)
80
81# +++ Dependency line eater +++
82#
83# Makefile dependencies follow.  This must be the last section in
84# the Makefile.in file
85#
86main.o: $(srcdir)/main.c $(srcdir)/ext2ed.h
87general_com.o: $(srcdir)/general_com.c $(srcdir)/ext2ed.h
88inode_com.o: $(srcdir)/inode_com.c $(srcdir)/ext2ed.h
89dir_com.o: $(srcdir)/dir_com.c $(srcdir)/ext2ed.h
90super_com.o: $(srcdir)/super_com.c $(srcdir)/ext2ed.h
91disk.o: $(srcdir)/disk.c $(srcdir)/ext2ed.h
92win.o: $(srcdir)/win.c $(srcdir)/ext2ed.h
93group_com.o: $(srcdir)/group_com.c $(srcdir)/ext2ed.h
94file_com.o: $(srcdir)/file_com.c $(srcdir)/ext2ed.h
95blockbitmap_com.o: $(srcdir)/blockbitmap_com.c $(srcdir)/ext2ed.h
96ext2_com.o: $(srcdir)/ext2_com.c $(srcdir)/ext2ed.h
97inodebitmap_com.o: $(srcdir)/inodebitmap_com.c $(srcdir)/ext2ed.h
98