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 ldlm ptlrpc osc lov obdecho \
9 mgc doc utils tests conf scripts autoconf
11 SERVER_SUBDIRS := ldiskfs obdfilter ost mds
14 CLIENT_SUBDIRS := mdc llite
16 LIBLUSTRE_SUBDIRS := liblustre
18 SUBDIRS := $(ALWAYS_SUBDIRS)
21 SUBDIRS += $(SERVER_SUBDIRS)
25 SUBDIRS += $(CLIENT_SUBDIRS)
28 # this needs to be after the client subdirs
31 SUBDIRS += $(CLIENT_SUBDIRS)
33 SUBDIRS += $(LIBLUSTRE_SUBDIRS)
36 DIST_SUBDIRS := $(ALWAYS_SUBDIRS) $(SERVER_SUBDIRS) $(CLIENT_SUBDIRS) \
39 EXTRA_DIST = BUGS FDL kernel_patches
42 LDISKFS = ldiskfs-sources
44 $(MAKE) sources -C ldiskfs
48 $(MAKE) sources -C lvfs
50 sources: $(LDISKFS) lvfs-sources lustre_build_version
52 all-recursive: lustre_build_version
55 perl $(top_builddir)/lustre/scripts/version_tag.pl $(top_srcdir) $(top_builddir) > tmpver
56 echo "#define LUSTRE_RELEASE @RELEASE@" >> tmpver
57 cmp -s $(top_builddir)/lustre/include/linux/lustre_build_version.h tmpver \
60 mv tmpver $(top_builddir)/lustre/include/linux/lustre_build_version.h
63 CSTKO=/tmp/checkstack.orig
66 [ -f ${CSTK} -a ! -s ${CSTKO} ] && mv ${CSTK} ${CSTKO} || true
67 for i in ${SUBDIRS} lnet/klnds/*; do \
68 MOD=$$i/`basename $$i`.o; \
69 [ -f $$MOD ] && objdump -d $$MOD | perl tests/checkstack.pl; \
70 done | sort -nr > ${CSTK}
71 [ -f ${CSTKO} ] && ! diff -u ${CSTKO} ${CSTK} || head -30 ${CSTK}
74 [ -f ${CSTK} ] && mv ${CSTK} ${CSTKO}
77 rm -f ${CSTK} ${CSTKO}