1 # Copyright (C) 2001 Cluster File Systems, Inc.
3 # This code is issued under the GNU General Public License.
4 # See the file COPYING in this distribution
6 AUTOMAKE_OPTIONS = foreign
8 ALWAYS_SUBDIRS := include lvfs obdclass lov ldlm sec ptlrpc \
9 obdecho osc lmv cobd ptlbd cmobd doc utils tests conf scripts \
12 SERVER_SUBDIRS := ldiskfs smfs snapfs obdfilter ost mds
14 CLIENT_SUBDIRS := mdc llite
16 LIBLUSTRE_SUBDIRS := liblustre
18 SUBDIRS := $(ALWAYS_SUBDIRS)
21 SUBDIRS += $(SERVER_SUBDIRS)
25 SUBDIRS += $(CLIENT_SUBDIRS)
30 SUBDIRS += $(CLIENT_SUBDIRS)
32 SUBDIRS += $(LIBLUSTRE_SUBDIRS)
35 DIST_SUBDIRS := $(ALWAYS_SUBDIRS) $(SERVER_SUBDIRS) $(CLIENT_SUBDIRS) \
38 EXTRA_DIST = BUGS FDL Rules.in kernel_patches
41 LDISKFS = ldiskfs-sources
43 $(MAKE) sources -C ldiskfs
47 $(MAKE) sources -C lvfs
49 sources: $(LDISKFS) lvfs-sources lustre_build_version
51 all-recursive: lustre_build_version
54 perl $(top_builddir)/lustre/scripts/version_tag.pl $(top_srcdir) $(top_builddir) > tmpver
55 echo "#define LUSTRE_RELEASE @RELEASE@" >> tmpver
56 cmp -s $(top_builddir)/lustre/include/linux/lustre_build_version.h tmpver \
59 mv tmpver $(top_builddir)/lustre/include/linux/lustre_build_version.h
62 CSTKO=/tmp/checkstack.orig
65 [ -f ${CSTK} -a ! -s ${CSTKO} ] && mv ${CSTK} ${CSTKO} || true
66 for i in ${SUBDIRS} portals/knals/*; do \
67 MOD=$$i/`basename $$i`.o; \
68 [ -f $$MOD ] && objdump -d $$MOD | perl tests/checkstack.pl; \
69 done | sort -nr > ${CSTK}
70 [ -f ${CSTKO} ] && ! diff -u ${CSTKO} ${CSTK} || head -30 ${CSTK}
73 [ -f ${CSTK} ] && mv ${CSTK} ${CSTKO}
76 rm -f ${CSTK} ${CSTKO}