Whamcloud - gitweb
Need to package the scripts in $libdir/lustre/.
[fs/lustre-release.git] / build / autoMakefile.am.toplevel
1 AUTOMAKE_OPTIONS = foreign
2
3 SUBDIRS := . build @LIBSYSIO_SUBDIR@ @SNMP_SUBDIR@ lnet @LUSTRE_PORTALS_SUBDIR@ lustre
4 DIST_SUBDIRS := build @SNMP_DIST_SUBDIR@ libsysio lnet @LUSTRE_PORTALS_SUBDIR@ lustre
5
6 EXTRA_DIST := config.h.in
7
8 # these empty rules are needed so that automake doesn't add its own
9 # recursive rules
10 etags-recursive:
11
12 ctags-recursive:
13
14 tags-recursive:
15
16 TAGS:
17
18 tags:
19         rm -f $(top_srcdir)/TAGS
20         ETAGSF=`etags --version | grep -iq exuberant && \
21                 echo "-I __initdata,__exitdata,EXPORT_SYMBOL"`; \
22         find $(top_srcdir) -name '*.[hc]' |grep -v linux-stage |xargs etags $$ETAGSF -a
23
24         rm -f $(top_srcdir)/tags
25         CTAGSF=`ctags --version | grep -iq exuberant && \
26                 echo "-I __initdata,__exitdata,EXPORT_SYMBOL"`; \
27         find $(top_srcdir) -name '*.[hc]' |grep -v linux-stage |xargs ctags $$CTAGSF -a
28
29 if MODULES
30 all-sources:
31         $(MAKE) sources -C lnet
32         $(MAKE) sources -C lustre
33         if [ "x@LUSTRE_PORTALS_SUBDIR@" = "xportals" ] ; then $(MAKE) sources -C @LUSTRE_PORTALS_SUBDIR@ ; fi
34
35 if LINUX
36 all-am: modules
37
38 if !LINUX25
39 DEP = dep
40 dep: .depend
41
42 .depend: all-sources
43         $(MAKE) $(ARCH_UM) CC="$(CC)" -C $(LINUX_OBJ)                \
44         -f $(PWD)/build/Makefile LUSTRE_LINUX_CONFIG=$(LINUX_CONFIG) \
45         -o scripts -o include/config/MARKER _sfdep_$(PWD)            \
46         _FASTDEP_ALL_SUB_DIRS="$(PWD)"
47
48 CLEANFILES = .depend
49 endif # !LINUX25
50
51 modules: $(DEP) all-sources
52         $(MAKE) $(ARCH_UM) CC="$(CC)" -C $(LINUX_OBJ)                \
53         -f $(PWD)/build/Makefile LUSTRE_LINUX_CONFIG=$(LINUX_CONFIG) \
54         $(MODULE_TARGET)=$(PWD) -o tmp_include_depends -o scripts -o \
55         include/config/MARKER $@
56 endif # LINUX
57
58 endif # MODULES
59
60 dist-hook:
61         find $(distdir) -name .deps -o \
62                         -name CVS -o \
63                         -name .svn -o \
64                         -name .#* | xargs rm -rf
65
66 build/lustre.spec: build/lustre.spec.in config.status
67         ./config.status build/lustre.spec
68
69 rpms: build/lustre.spec dist Makefile
70         rpmbuild -ta $(distdir).tar.gz
71
72 srpm: build/lustre.spec dist Makefile
73         rpmbuild -ts $(distdir).tar.gz