Whamcloud - gitweb
1582666df811ee331d6005e4a01ee54d5fc8817c
[fs/lustre-release.git] / lustre / Makefile.am
1 # Copyright (C) 2001  Cluster File Systems, Inc.
2 #
3 # This code is issued under the GNU General Public License.
4 # See the file COPYING in this distribution
5
6 AUTOMAKE_OPTIONS = foreign
7
8 if LINUX25
9 DIRS24 = 
10 else
11 DIRS24 = ptlbd
12 endif
13
14 if LIBLUSTRE
15 SUBDIRS = portals obdclass lov ptlrpc obdecho  osc utils mdc lvfs #liblustre
16 else
17 SUBDIRS = lvfs portals obdclass include $(DIRS24) mds utils obdfilter mdc osc ost 
18 SUBDIRS+= llite obdecho lov cobd tests doc scripts conf ptlrpc
19 endif
20
21 if SNAPFS
22 SUBDIRS+= snapfs
23 endif
24
25 if SMFS 
26 SUBDIRS += smfs
27 endif
28 DIST_SUBDIRS = $(SUBDIRS) liblustre snapfs smfs
29 EXTRA_DIST = BUGS FDL Rules kernel_patches
30
31 # We get the version from the spec file.
32 CONFIGURE_DEPENDENCIES = scripts/lustre.spec.in
33
34 dist-hook:
35         find $(distdir) -name .deps | xargs rm -rf
36         find $(distdir) -name CVS | xargs rm -rf
37
38 include $(top_srcdir)/Rules
39
40 rpms: dist Makefile
41         rpmbuild -ta $(distdir).tar.gz
42
43 CSTK=/tmp/checkstack
44 CSTKO=/tmp/checkstack.orig
45
46 checkstack:
47         [ -f ${CSTK} -a ! -s ${CSTKO} ] && mv ${CSTK} ${CSTKO} || true
48         for i in ${SUBDIRS} portals/knals/*; do                              \
49                 MOD=$$i/`basename $$i`.o;                                    \
50                 [ -f $$MOD ] && objdump -d $$MOD | perl tests/checkstack.pl; \
51         done | sort -nr > ${CSTK}
52         [ -f ${CSTKO} ] && ! diff -u ${CSTKO} ${CSTK} || head -30 ${CSTK}
53
54 checkstack-update:
55         [ -f ${CSTK} ] && mv ${CSTK} ${CSTKO}
56
57 checkstack-clean:
58         rm -f ${CSTK} ${CSTKO}