summaryrefslogtreecommitdiff
path: root/scripts/Makefile
diff options
context:
space:
mode:
authorSam Ravnborg <sam@mars.ravnborg.org>2002-08-16 01:08:11 +0200
committerSam Ravnborg <sam@mars.ravnborg.org>2002-08-16 01:08:11 +0200
commitead1d4e1cda81ca5bf53788fb0bd892d720fc7ee (patch)
tree0caa447e9f770a687f1717929c0af8b5f376f712 /scripts/Makefile
parentd572f1a54f926381a04163c352cb4abe4824782b (diff)
[PATCH] kbuild: Moved conmakehash to scripts
- Suggested by David Miller to avoid a race with make -j Furthermore cleaned up a little in scripts/Makefile - Use $(obj) - Added a few comments
Diffstat (limited to 'scripts/Makefile')
-rw-r--r--scripts/Makefile67
1 files changed, 33 insertions, 34 deletions
diff --git a/scripts/Makefile b/scripts/Makefile
index 1efc9dc8ba49..a18193a4e838 100644
--- a/scripts/Makefile
+++ b/scripts/Makefile
@@ -1,58 +1,57 @@
-
-# always needed
+###
+# scripts contains sources for various helper programs used throughout
+# the kernel for the build process.
# ---------------------------------------------------------------------------
+# fix-dep: Used to generate dependency information during build process
+# split-include: Divide all config symbols up in a number of files in
+# include/config/...
+# docproc: Preprocess .tmpl file in order to generate .sgml documentation
+# conmakehash: Create arrays for initializing the kernel console tables
+# tkparse: Used by xconfig
# The following temporary rule will make sure that people's
# trees get updated to the right permissions, since patch(1)
# can't do it
CHMOD_FILES := kernel-doc mkcompile_h makelst
-all: fixdep split-include docproc $(CHMOD_FILES)
+all: fixdep split-include docproc conmakehash $(CHMOD_FILES)
-$(CHMOD_FILES): FORCE
- @chmod a+x $@
+host-progs := fixdep split-include conmakehash docproc tkparse
+tkparse-objs := tkparse.o tkcond.o tkgen.o
-# xconfig
-# ---------------------------------------------------------------------------
+include $(TOPDIR)/Rules.make
-HEADER=header.tk
-TAIL=tail.tk
-# Previous versions always remade kconfig.tk because they always depended
-# on soundscript. This runs fairly fast, and I can't find all the
-# Config.in files to depend on anyways. So I'll force it to remake.
+$(CHMOD_FILES): FORCE
+ @chmod a+x $@
-kconfig.tk: $(TOPDIR)/arch/$(ARCH)/config.in tkparse $(HEADER) $(TAIL) FORCE
+# In reality kconfig.tk should depend on all Config.in files,
+# but it is not worth the effort to generate the dependencies.
+# The alternative solution to always generate it is fairly fast.
+# FORCE it to remake
+$(obj)/kconfig.tk: $(srctree)/arch/$(ARCH)/config.in tkparse FORCE
@echo ' Generating $@'
@( \
- if [ -f /usr/local/bin/wish ]; then \
+ if [ -f /usr/local/bin/wish ]; then \
echo '#!'"/usr/local/bin/wish -f"; \
- else \
+ else \
echo '#!'"/usr/bin/wish -f"; \
- fi; \
- cat $(HEADER); \
- ./tkparse < $<; \
- echo "set defaults \"arch/${ARCH}/defconfig\""; \
- echo "set ARCH \"${ARCH}\""; \
- cat $(TAIL) \
+ fi; \
+ cat $(src)/header.tk; \
+ $(obj)/tkparse < $<; \
+ echo "set defaults \"arch/${ARCH}/defconfig\""; \
+ echo "set ARCH \"${ARCH}\""; \
+ cat $(src)/tail.tk; \
) > $@
- chmod 755 $@
+ @chmod 755 $@
-# ---------------------------------------------------------------------------
+# ---------------------------------------------------------------------------
+# Targets hardcoded and wellknow in top-level makefile
.PHONY: lxdialog
-
lxdialog:
$(MAKE) -C lxdialog all
-# ---------------------------------------------------------------------------
-
-host-progs := fixdep split-include docproc tkparse
-
-tkparse-objs := tkparse.o tkcond.o tkgen.o
-
# fixdep is needed to compile other host programs
+$(obj)/split-include $(obj)/docproc $(addprefix $(obj)/,$(tkparse-objs)) \
+$(obj)/conmakehash lxdialog: $(obj)/fixdep
-split-include docproc $(tkparse-objs) lxdialog: fixdep
-
-
-include $(TOPDIR)/Rules.make