Whamcloud - gitweb
b=19919 Supply a absolute path.
[fs/lustre-release.git] / autoMakefile.am
index f31200a..87f7181 100644 (file)
@@ -1,21 +1,34 @@
+SUBDIRS := @LDISKFS_SUBDIR@ @SPL_SUBDIR@ @ZFS_SUBDIR@ . @LIBSYSIO_SUBDIR@ @SNMP_SUBDIR@ @LUSTREIOKIT_SUBDIR@ @LIBCFS_SUBDIR@ lnet lustre
+DIST_SUBDIRS := @SNMP_DIST_SUBDIR@ libsysio ldiskfs @LUSTREIOKIT_SUBDIR@ @LIBCFS_SUBDIR@ lnet lustre 
+SOURCES_SUBDIRS := @LDISKFS_SUBDIR@ @LIBCFS_SUBDIR@ lnet lustre
+RPM_SUBDIRS := @LDISKFS_SUBDIR@ @LUSTREIOKIT_SUBDIR@
+if LDISKFS_ENABLED
+if !LDISKFS_IN_KERNEL
+EXTRA_SOURCES := @SYMVERFILE@
+endif
+endif
+
 include build/autoMakefile.am.toplevel
 
+EXTRA_DIST += config.h.in debian/*
+
+if LDISKFS_ENABLED
+if !LDISKFS_IN_KERNEL
+@SYMVERFILE@: @LDISKFS_DIR@/@SYMVERFILE@
+       touch @SYMVERFILE@
+       -grep -v ldiskfs @SYMVERFILE@ > @SYMVERFILE@.old
+       cat @SYMVERFILE@.old @LDISKFS_DIR@/@SYMVERFILE@ > @SYMVERFILE@
+endif
+endif
+
 CSTK=/tmp/checkstack
 CSTKO=/tmp/checkstack.orig
 
 checkstack:
        [ -f ${CSTK} -a ! -s ${CSTKO} ] && mv -f ${CSTK} ${CSTKO} || true
-       { for i in lustre/* lnet/* ; do                                      \
-               MOD=$$i/`basename $$i`;                                      \
-               if [ $$i = "lustre/llite" ]; then MOD=$$i/lustre; fi;        \
-               [ -f $$MOD.ko ] && MOD=$$MOD.ko || MOD=$$MOD.o;              \
-               [ -f $$MOD ] && objdump -d $$MOD | perl build/checkstack.pl; \
-         done;                                                              \
-         for i in lnet/klnds/*; do                                          \
-               MOD=$$i/k`basename $$i`;                                     \
-               [ -f $$MOD.ko ] && MOD=$$MOD.ko || MOD=$$MOD.o;              \
-               [ -f $$MOD ] && objdump -d $$MOD | perl build/checkstack.pl; \
-         done } | sort -nr > ${CSTK}
+       { for MOD in $$(find . -name "*.ko"); do                             \
+               objdump -d $$MOD | perl build/checkstack.pl;                 \
+         done } | grep -v " bug " | sort -nr | uniq > ${CSTK}
        [ -f ${CSTKO} ] && ! diff -u ${CSTKO} ${CSTK} || head -30 ${CSTK}
 
 checkstack-update:
@@ -23,3 +36,12 @@ checkstack-update:
 
 checkstack-clean:
        rm -f ${CSTK} ${CSTKO}
+
+module-dist-hook:
+       if [ -d CVS -o -d .git ]; then \
+           perl lustre/scripts/tree_status.pl > $(distdir)/tree_status; \
+       elif [ -f tree_status ]; then \
+           cp tree_status $(distdir)/tree_status; \
+       else \
+           echo -e "I have no idea how to create a tree_status file in $(distdir).\nPlease file a bug at http://bugzilla.lustre.org/"; \
+       fi