Whamcloud - gitweb
b=21632 Kernel update for RHEL5.4 2.6.18-164.11.1.el5.
[fs/lustre-release.git] / build / Makefile
index db3bd45..11c9c6e 100644 (file)
@@ -1,15 +1,17 @@
 #
-# There are three ways this Makefile can be called:
+# There are four ways this Makefile can be called:
 #
 # 
 # 1.  As a subdirectory from the toplevel, for automake
 #
-# 2. A wrapper around the kernel's makefile when building modules, to
-#    possibly override the .config file
+# 2.  A wrapper around the kernel's makefile when building modules, to
+#     possibly override the .config file
 #
 # 3.  At configure time, as the toplevel module dir for building
 #     kernel tests
 #
+# 4.  At configure time, to determine the kernel's idea of $(ARCH)
+#
 
 ifeq ($(PATCHLEVEL),)
 
@@ -21,6 +23,8 @@ include autoMakefile
 else
 
 # case #2
+# Note that this comes from make -C $LINUX -f $LUSTRE/build/Makefile
+# so "include Makefile" below includes $LINUX/Makefile, not this file
 include $(LUSTRE_LINUX_CONFIG)
 include Makefile
 
@@ -45,3 +49,8 @@ include $(TOPDIR)/Rules.make
 endif
 
 endif # PATCHLEVEL
+
+# case 4
+
+echoarch:
+       echo $(ARCH) >$(ARCHFILE)