Whamcloud - gitweb
b=2623
[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 DIST_SUBDIRS = $(SUBDIRS) liblustre snapfs
26 EXTRA_DIST = BUGS FDL Rules kernel_patches
27
28 # We get the version from the spec file.
29 CONFIGURE_DEPENDENCIES = scripts/lustre.spec.in
30
31 dist-hook:
32         find $(distdir) -name .deps | xargs rm -rf
33         find $(distdir) -name CVS | xargs rm -rf
34
35 include $(top_srcdir)/Rules
36
37 rpms: dist Makefile
38         rpmbuild -ta $(distdir).tar.gz
39
40 CSTK=/tmp/checkstack
41 CSTKO=/tmp/checkstack.orig
42
43 checkstack:
44         [ -f ${CSTK} -a ! -s ${CSTKO} ] && mv ${CSTK} ${CSTKO} || true
45         for i in ${SUBDIRS} portals/knals/*; do                              \
46                 MOD=$$i/`basename $$i`.o;                                    \
47                 [ -f $$MOD ] && objdump -d $$MOD | perl tests/checkstack.pl; \
48         done | sort -nr > ${CSTK}
49         [ -f ${CSTKO} ] && ! diff -u ${CSTKO} ${CSTK} || head -30 ${CSTK}
50
51 checkstack-update:
52         [ -f ${CSTK} ] && mv ${CSTK} ${CSTKO}
53
54 checkstack-clean:
55         rm -f ${CSTK} ${CSTKO}