diff --git a/build/autoMakefile.am.toplevel b/build/autoMakefile.am.toplevel new file mode 100644 index 0000000000000000000000000000000000000000..aa19a1e403146e19fb7d48ac0b04cf6152617da7 --- /dev/null +++ b/build/autoMakefile.am.toplevel @@ -0,0 +1,103 @@ +# This file is included by each package's toplevel autoMakefile[.am], +# which must define SUBDIRS as a minimum. + +AUTOMAKE_OPTIONS = foreign + +# these empty rules are needed so that automake doesn't add its own +# recursive rules +etags-recursive: + +ctags-recursive: + +tags-recursive: + +TAGS: + +tags: + $(RM) $(top_srcdir)/TAGS + ETAGSF=`etags --version | grep -iq exuberant && \ + echo "-I __initdata,__exitdata,EXPORT_SYMBOL"`; \ + find $(top_srcdir) -name .pc -prune -o -name '*.[hc]' |xargs etags $$ETAGSF -a + + $(RM) $(top_srcdir)/tags + CTAGSF=`ctags --version | grep -iq exuberant && \ + echo "-I __initdata,__exitdata,EXPORT_SYMBOL"`; \ + find $(top_srcdir) -name .pc -prune -o -name '*.[hc]' |xargs ctags $$CTAGSF -a + +if MODULES +sources: all-sources + +all-sources: $(EXTRA_SOURCES) + for dir in $(SOURCES_SUBDIRS) ; do \ + $(MAKE) sources -C $$dir || exit $$? ; \ + done + +if LINUX +all-am: modules + +if !LINUX25 +DEP = dep +dep: .depend + +.depend: all-sources + $(MAKE) $(ARCH_UM) CC="$(CC)" -C $(LINUX_OBJ) \ + -f $(PWD)/build/Makefile LUSTRE_LINUX_CONFIG=$(LINUX_CONFIG) \ + -o scripts -o include/config/MARKER _sfdep_$(PWD) \ + _FASTDEP_ALL_SUB_DIRS="$(PWD)" + +CLEANFILES = .depend +endif # !LINUX25 + +modules: $(DEP) all-sources + $(MAKE) $(ARCH_UM) CC="$(CC)" -C $(LINUX_OBJ) \ + -f $(PWD)/build/Makefile LUSTRE_LINUX_CONFIG=$(LINUX_CONFIG) \ + LINUXINCLUDE='$(EXTRA_LNET_INCLUDE) -Iinclude $$(if $$(KBUILD_SRC),-Iinclude2 -I$$(srctree)/include) -include include/linux/autoconf.h' \ + $(MODULE_TARGET)=$(PWD) -o tmp_include_depends -o scripts -o \ + include/config/MARKER $@ +endif # LINUX + +endif # MODULES + +dist-hook: + $(RM) $(distdir)/ldiskfs/*.spec + $(RM) $(distdir)/lustre-iokit/*.spec + find $(distdir) -name .deps -o \ + -name CVS -o \ + -name .svn -o \ + -name .#* | xargs rm -rf + +EXTRA_DIST = @PACKAGE_TARNAME@.spec \ + build/Makefile build/autoMakefile.am.toplevel build/lbuild \ + build/linux-merge-config.awk build/linux-merge-modules.awk \ + build/linux-rhconfig.h build/lmake build/Rules.in \ + build/lustre-kernel-2.4.spec.in build/suse-functions.sh \ + build/suse-post.sh build/suse-postun.sh \ + build/suse-trigger-script.sh.in build/README.kernel-source \ + build/sles8-post.sh build/sles8-postun.sh build/sles8-pre.sh \ + build/sles8-update_INITRD_MODULES.sh \ + build/sles8-update_rcfile_setting.sh build/update_oldconfig \ + build/autoconf/lustre-build-linux.m4 \ + build/autoconf/lustre-build.m4 + +rpms-real: @PACKAGE_TARNAME@.spec dist Makefile + rpmbuild -ta $(distdir).tar.gz + +srpm-real: @PACKAGE_TARNAME@.spec dist Makefile + rpmbuild -ts $(distdir).tar.gz + +rpms: + for subdir in $(RPM_SUBDIRS) ; do \ + echo "Making rpms in $$subdir"; \ + (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) rpms); \ + echo "Finished rpms in $$subdir"; \ + done; \ + $(MAKE) $(AM_MAKEFLAGS) rpms-real + +srpm: + for subdir in $(RPM_SUBDIRS) ; do \ + echo "Making srpm in $$subdir"; \ + (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) srpm); \ + echo "Finished srpms in $$subdir"; \ + done; \ + $(MAKE) $(AM_MAKEFLAGS) srpm-real +