Theodore Ts'o | 50e1e10 | 1997-04-26 13:58:21 +0000 | [diff] [blame] | 1 | srcdir = @srcdir@ |
| 2 | top_srcdir = @top_srcdir@ |
| 3 | VPATH = @srcdir@ |
| 4 | top_builddir = . |
Theodore Ts'o | fc6d9d5 | 1997-04-29 14:51:31 +0000 | [diff] [blame] | 5 | my_dir = . |
Theodore Ts'o | 50e1e10 | 1997-04-26 13:58:21 +0000 | [diff] [blame] | 6 | INSTALL = @INSTALL@ |
| 7 | |
| 8 | @MCONFIG@ |
| 9 | |
Theodore Ts'o | cdf186e | 2001-06-13 22:16:47 +0000 | [diff] [blame] | 10 | @RESIZER_CMT@RESIZE_DIR= resize |
| 11 | @DEBUGFS_CMT@DEBUGFS_DIR= debugfs |
| 12 | |
Theodore Ts'o | a04eba3 | 2003-05-03 16:35:17 -0400 | [diff] [blame] | 13 | LIB_SUBDIRS=lib/et lib/ss lib/e2p lib/ext2fs lib/uuid lib/blkid intl |
Theodore Ts'o | 921f4ad | 2004-11-19 17:25:27 -0500 | [diff] [blame] | 14 | PROG_SUBDIRS=e2fsck $(DEBUGFS_DIR) misc $(RESIZE_DIR) tests/progs po |
Theodore Ts'o | f3b3dbb | 1999-07-19 16:18:52 +0000 | [diff] [blame] | 15 | SUBDIRS=util $(LIB_SUBDIRS) $(PROG_SUBDIRS) tests |
Theodore Ts'o | 50e1e10 | 1997-04-26 13:58:21 +0000 | [diff] [blame] | 16 | |
Theodore Ts'o | 94ba8c7 | 2003-03-02 02:07:14 -0500 | [diff] [blame] | 17 | SUBS= lib/ext2fs/ext2_types.h lib/blkid/blkid_types.h lib/uuid/uuid_types.h |
Theodore Ts'o | 50e1e10 | 1997-04-26 13:58:21 +0000 | [diff] [blame] | 18 | |
Theodore Ts'o | 21c84b7 | 1997-04-29 16:15:03 +0000 | [diff] [blame] | 19 | TAR=tar |
| 20 | |
Theodore Ts'o | 78130a2 | 2003-03-14 02:42:42 -0500 | [diff] [blame] | 21 | all:: subs |
Theodore Ts'o | 6928adc | 2000-05-25 23:28:50 +0000 | [diff] [blame] | 22 | $(MAKE) libs |
| 23 | $(MAKE) progs |
| 24 | $(MAKE) docs |
Theodore Ts'o | a4d0961 | 1997-04-29 14:28:00 +0000 | [diff] [blame] | 25 | |
Theodore Ts'o | 94ba8c7 | 2003-03-02 02:07:14 -0500 | [diff] [blame] | 26 | subs: |
Theodore Ts'o | 47204ff | 2004-11-30 10:52:27 -0500 | [diff] [blame] | 27 | @for i in $(SUBS) ; do if test -d `dirname $$i` ; then $(MAKE) $$i ; fi ; done |
Theodore Ts'o | 94ba8c7 | 2003-03-02 02:07:14 -0500 | [diff] [blame] | 28 | |
| 29 | progs: subs all-progs-recursive |
| 30 | libs: subs all-libs-recursive |
Theodore Ts'o | 50e1e10 | 1997-04-26 13:58:21 +0000 | [diff] [blame] | 31 | |
Theodore Ts'o | 21c84b7 | 1997-04-29 16:15:03 +0000 | [diff] [blame] | 32 | docs: |
Theodore Ts'o | 47204ff | 2004-11-30 10:52:27 -0500 | [diff] [blame] | 33 | -@test -d doc && cd doc && $(MAKE) libext2fs.info |
Theodore Ts'o | 21c84b7 | 1997-04-29 16:15:03 +0000 | [diff] [blame] | 34 | |
| 35 | install-doc-libs: |
Theodore Ts'o | 47204ff | 2004-11-30 10:52:27 -0500 | [diff] [blame] | 36 | -@test -d doc && cd doc && $(MAKE) install-doc-libs |
Theodore Ts'o | 21c84b7 | 1997-04-29 16:15:03 +0000 | [diff] [blame] | 37 | |
Theodore Ts'o | a4b2d3c | 1998-04-03 16:12:25 +0000 | [diff] [blame] | 38 | uninstall-doc-libs: |
Theodore Ts'o | 47204ff | 2004-11-30 10:52:27 -0500 | [diff] [blame] | 39 | -@test -d doc && cd doc && $(MAKE) uninstall-doc-libs |
Theodore Ts'o | a4b2d3c | 1998-04-03 16:12:25 +0000 | [diff] [blame] | 40 | |
Theodore Ts'o | 3ac9f0e | 1999-07-19 21:02:11 +0000 | [diff] [blame] | 41 | clean-doc: |
Theodore Ts'o | 47204ff | 2004-11-30 10:52:27 -0500 | [diff] [blame] | 42 | -@test -d doc && cd doc && $(MAKE) clean |
Theodore Ts'o | 3ac9f0e | 1999-07-19 21:02:11 +0000 | [diff] [blame] | 43 | |
| 44 | distclean-doc: |
Theodore Ts'o | 94ba8c7 | 2003-03-02 02:07:14 -0500 | [diff] [blame] | 45 | -test -d doc && cd doc && $(MAKE) distclean |
Theodore Ts'o | 3ac9f0e | 1999-07-19 21:02:11 +0000 | [diff] [blame] | 46 | |
Theodore Ts'o | 94ba8c7 | 2003-03-02 02:07:14 -0500 | [diff] [blame] | 47 | install: subs all-libs-recursive install-progs-recursive \ |
Theodore Ts'o | 522798d | 2004-12-15 11:28:55 -0500 | [diff] [blame] | 48 | install-shlibs-libs-recursive install-doc-libs |
Theodore Ts'o | 56eb4d4 | 2004-09-17 19:54:22 -0400 | [diff] [blame] | 49 | if test ! -d e2fsck && test ! -d debugfs && test ! -d misc && test ! -d ext2ed ; then $(MAKE) install-libs ; fi |
Theodore Ts'o | 50e1e10 | 1997-04-26 13:58:21 +0000 | [diff] [blame] | 50 | |
Theodore Ts'o | 522798d | 2004-12-15 11:28:55 -0500 | [diff] [blame] | 51 | install-strip: subs all-libs-recursive install-strip-progs-recursive \ |
| 52 | install-shlibs-strip-libs-recursive install-doc-libs |
| 53 | |
Theodore Ts'o | a4b2d3c | 1998-04-03 16:12:25 +0000 | [diff] [blame] | 54 | uninstall: uninstall-progs-recursive uninstall-shlibs-libs-recursive uninstall-doc-libs |
| 55 | |
Theodore Ts'o | 50e1e10 | 1997-04-26 13:58:21 +0000 | [diff] [blame] | 56 | install-libs: install-libs-recursive |
| 57 | |
Theodore Ts'o | a4b2d3c | 1998-04-03 16:12:25 +0000 | [diff] [blame] | 58 | uninstall-libs: uninstall-libs-recursive |
| 59 | |
Theodore Ts'o | 3e377db | 2000-12-09 02:37:33 +0000 | [diff] [blame] | 60 | TAGS clean-recursive distclean-recursive depend-recursive check-recursive \ |
Theodore Ts'o | 522798d | 2004-12-15 11:28:55 -0500 | [diff] [blame] | 61 | mostlyclean-recursive realclean-recursive: |
Theodore Ts'o | 47204ff | 2004-11-30 10:52:27 -0500 | [diff] [blame] | 62 | @for subdir in $(SUBDIRS); do \ |
Theodore Ts'o | 24b2c7a | 1997-06-07 20:42:58 +0000 | [diff] [blame] | 63 | if test -d $$subdir ; then \ |
| 64 | target=`echo $@|$(SED) 's/-recursive//'`; \ |
| 65 | echo making $$target in $$subdir; \ |
| 66 | (cd $$subdir && $(MAKE) $$target) || exit 1; \ |
| 67 | fi ; \ |
Theodore Ts'o | 50e1e10 | 1997-04-26 13:58:21 +0000 | [diff] [blame] | 68 | done |
| 69 | |
Theodore Ts'o | 522798d | 2004-12-15 11:28:55 -0500 | [diff] [blame] | 70 | all-progs-recursive install-progs-recursive install-strip-progs-recursive \ |
| 71 | uninstall-progs-recursive: |
Theodore Ts'o | 47204ff | 2004-11-30 10:52:27 -0500 | [diff] [blame] | 72 | @for subdir in $(PROG_SUBDIRS); do \ |
Theodore Ts'o | 24b2c7a | 1997-06-07 20:42:58 +0000 | [diff] [blame] | 73 | if test -d $$subdir ; then \ |
| 74 | target=`echo $@|$(SED) 's/-progs-recursive//'`; \ |
| 75 | echo making $$target in $$subdir; \ |
| 76 | (cd $$subdir && $(MAKE) $$target) || exit 1; \ |
| 77 | fi ; \ |
Theodore Ts'o | 50e1e10 | 1997-04-26 13:58:21 +0000 | [diff] [blame] | 78 | done |
| 79 | |
Theodore Ts'o | 522798d | 2004-12-15 11:28:55 -0500 | [diff] [blame] | 80 | all-libs-recursive install-libs-recursive install-strip-libs-recursive \ |
| 81 | uninstall-libs-recursive install-shlibs-libs-recursive \ |
| 82 | install-shlibs-strip-libs-recursive uninstall-shlibs-libs-recursive: |
Theodore Ts'o | 47204ff | 2004-11-30 10:52:27 -0500 | [diff] [blame] | 83 | @for subdir in $(LIB_SUBDIRS); do \ |
Theodore Ts'o | 24b2c7a | 1997-06-07 20:42:58 +0000 | [diff] [blame] | 84 | if test -d $$subdir ; then \ |
| 85 | target=`echo $@|$(SED) 's/-libs-recursive//'`; \ |
| 86 | echo making $$target in $$subdir; \ |
| 87 | (cd $$subdir && $(MAKE) $$target) || exit 1; \ |
| 88 | fi ; \ |
Theodore Ts'o | 50e1e10 | 1997-04-26 13:58:21 +0000 | [diff] [blame] | 89 | done |
| 90 | |
| 91 | mostlyclean: mostlyclean-recursive mostlyclean-local |
Theodore Ts'o | a4d0961 | 1997-04-29 14:28:00 +0000 | [diff] [blame] | 92 | |
Theodore Ts'o | 3ac9f0e | 1999-07-19 21:02:11 +0000 | [diff] [blame] | 93 | clean: clean-recursive clean-local clean-doc |
Theodore Ts'o | 605e6f0 | 2004-11-30 22:06:27 -0500 | [diff] [blame] | 94 | $(RM) -f $(SUBS) |
Theodore Ts'o | a4d0961 | 1997-04-29 14:28:00 +0000 | [diff] [blame] | 95 | |
Theodore Ts'o | 3ac9f0e | 1999-07-19 21:02:11 +0000 | [diff] [blame] | 96 | distclean: distclean-doc distclean-recursive distclean-local |
Theodore Ts'o | 605e6f0 | 2004-11-30 22:06:27 -0500 | [diff] [blame] | 97 | $(RM) -rf autom4te.cache e2fsprogs.spec ext2ed/Makefile po/stamp-po |
Theodore Ts'o | a4d0961 | 1997-04-29 14:28:00 +0000 | [diff] [blame] | 98 | |
Theodore Ts'o | 50e1e10 | 1997-04-26 13:58:21 +0000 | [diff] [blame] | 99 | realclean: realclean-recursive realclean-local |
| 100 | |
Theodore Ts'o | 9d564f7 | 1999-07-03 20:25:58 +0000 | [diff] [blame] | 101 | depend:: depend-recursive |
| 102 | |
Theodore Ts'o | 797f5ef | 2001-06-01 23:49:46 +0000 | [diff] [blame] | 103 | lib/ext2fs/ext2_types.h: $(DEP_SUBSTITUTE) $(srcdir)/lib/ext2fs/ext2_types.h.in |
Theodore Ts'o | 47204ff | 2004-11-30 10:52:27 -0500 | [diff] [blame] | 104 | @echo " SUBST $@" |
| 105 | @$(SUBSTITUTE) $(srcdir)/lib/ext2fs/ext2_types.h.in \ |
Theodore Ts'o | 797f5ef | 2001-06-01 23:49:46 +0000 | [diff] [blame] | 106 | > lib/ext2fs/ext2_types.h |
Theodore Ts'o | a4d0961 | 1997-04-29 14:28:00 +0000 | [diff] [blame] | 107 | |
Theodore Ts'o | ed1b33e | 2003-03-01 19:29:01 -0500 | [diff] [blame] | 108 | lib/blkid/blkid_types.h: $(DEP_SUBSTITUTE) $(srcdir)/lib/blkid/blkid_types.h.in |
Theodore Ts'o | 47204ff | 2004-11-30 10:52:27 -0500 | [diff] [blame] | 109 | @echo " SUBST $@" |
| 110 | @$(SUBSTITUTE) $(srcdir)/lib/blkid/blkid_types.h.in \ |
Theodore Ts'o | ed1b33e | 2003-03-01 19:29:01 -0500 | [diff] [blame] | 111 | > lib/blkid/blkid_types.h |
| 112 | |
Theodore Ts'o | 94ba8c7 | 2003-03-02 02:07:14 -0500 | [diff] [blame] | 113 | lib/uuid/uuid_types.h: $(DEP_SUBSTITUTE) $(srcdir)/lib/uuid/uuid_types.h.in |
Theodore Ts'o | 47204ff | 2004-11-30 10:52:27 -0500 | [diff] [blame] | 114 | @echo " SUBST $@" |
| 115 | @$(SUBSTITUTE) $(srcdir)/lib/uuid/uuid_types.h.in \ |
Theodore Ts'o | 94ba8c7 | 2003-03-02 02:07:14 -0500 | [diff] [blame] | 116 | > lib/uuid/uuid_types.h |
| 117 | |
Theodore Ts'o | 50e1e10 | 1997-04-26 13:58:21 +0000 | [diff] [blame] | 118 | mostlyclean-local: |
Andreas Dilger | 83d0b97 | 2001-08-04 01:02:34 -0600 | [diff] [blame] | 119 | $(RM) -f \#* *~ *.orig core MAKELOG |
Theodore Ts'o | 5c36a2f | 1999-11-19 18:42:30 +0000 | [diff] [blame] | 120 | |
Theodore Ts'o | 50e1e10 | 1997-04-26 13:58:21 +0000 | [diff] [blame] | 121 | clean-local: mostlyclean-local |
Theodore Ts'o | 5c36a2f | 1999-11-19 18:42:30 +0000 | [diff] [blame] | 122 | |
Theodore Ts'o | 50e1e10 | 1997-04-26 13:58:21 +0000 | [diff] [blame] | 123 | distclean-local: clean-local |
Andreas Dilger | 83d0b97 | 2001-08-04 01:02:34 -0600 | [diff] [blame] | 124 | $(RM) -f $(SUBS) $(SUBST_CONF) \ |
Theodore Ts'o | 5c36a2f | 1999-11-19 18:42:30 +0000 | [diff] [blame] | 125 | config.status config.log config.cache MCONFIG Makefile \ |
| 126 | $(srcdir)/TAGS $(srcdir)/Makefile.in.old |
| 127 | |
Theodore Ts'o | 50e1e10 | 1997-04-26 13:58:21 +0000 | [diff] [blame] | 128 | realclean-local: distclean-local |
| 129 | $(RM) -f configure |
| 130 | |
Theodore Ts'o | 94ba8c7 | 2003-03-02 02:07:14 -0500 | [diff] [blame] | 131 | check:: subs check-recursive |
Theodore Ts'o | 50e1e10 | 1997-04-26 13:58:21 +0000 | [diff] [blame] | 132 | |