summaryrefslogtreecommitdiff
path: root/stepmake
diff options
context:
space:
mode:
authorJohn Mandereau - LilyPond development <john.mandereau@gmail.com>2012-06-28 18:32:18 +0200
committerJohn Mandereau <john.mandereau@gmail.com>2012-06-29 16:40:55 +0200
commite6a5019c531bbc6663e0eebc645409148dbd8931 (patch)
treef318b775ad7ac8b8fd8e6138ff3ae7c11703c4d5 /stepmake
parent512d405d07aba8742658902b105a94ebbd40c2dc (diff)
Clean fonts and docs makefiles, trying to fix 'make -j' race conditions
On my machine (GNU/Linux Fedora 17 x86_64 on an Intel Core 2 Duo), "make -j3 all" repeatedly calls fontforge before needed .pfb files are generated and makeinfo/extract_texi_filenames/texi2omf before .texi file has been generated/copied. Fix this by using order prerequisites and adding targets to WWW-1 (first stage of doc build); order (rather than ordinary) prerequisites avoid having always outdated targets, which would trigger compilation at install. Remove a rule for Info manual that is no longer needed and which might short-circuit .dep file generation. mf/GNUmakefile: also factorize prerequisites in fonts using a macro.
Diffstat (limited to 'stepmake')
-rw-r--r--stepmake/stepmake/metafont-rules.make4
-rw-r--r--stepmake/stepmake/metafont-targets.make1
-rw-r--r--stepmake/stepmake/texinfo-rules.make19
-rw-r--r--stepmake/stepmake/texinfo-targets.make2
4 files changed, 12 insertions, 14 deletions
diff --git a/stepmake/stepmake/metafont-rules.make b/stepmake/stepmake/metafont-rules.make
index 6d81f550ac..5b6ad17d91 100644
--- a/stepmake/stepmake/metafont-rules.make
+++ b/stepmake/stepmake/metafont-rules.make
@@ -18,8 +18,8 @@ $(outdir)/%.tfm $(outdir)/%.log: %.mf
#
# the soft link for mf2pt1.mp is for recent mpost versions
# which no longer dump a .mem file
-$(outdir)/%.pfb: %.mf $(outdir)/mf2pt1.mem
- TMP=`mktemp -d $(outdir)/pfbtemp.XXXXXXXXX` \
+$(outdir)/%.pfb: %.mf $(outdir)/mf2pt1.mem $(outdir)/%.log
+ TMP=`mktemp -d $(outdir)/pfbtemp.$*.XXXXXXXXX` \
&& ( cd $$TMP \
&& ln -s ../mf2pt1.mem . \
&& ln -s ../../mf2pt1.mp . \
diff --git a/stepmake/stepmake/metafont-targets.make b/stepmake/stepmake/metafont-targets.make
index dfaf2c18ce..89dfd628e0 100644
--- a/stepmake/stepmake/metafont-targets.make
+++ b/stepmake/stepmake/metafont-targets.make
@@ -1,3 +1,4 @@
+.PHONY: tfm dvi pfb
tfm: $(TFM_FILES)
diff --git a/stepmake/stepmake/texinfo-rules.make b/stepmake/stepmake/texinfo-rules.make
index 074060627e..838219a673 100644
--- a/stepmake/stepmake/texinfo-rules.make
+++ b/stepmake/stepmake/texinfo-rules.make
@@ -32,25 +32,25 @@ $(outdir)/%.itexi: %.itexi
mkdir -p $(dir $@)
$(DO_TEXI_DEP) cp -f $< $@
-$(outdir)/%.info: $(outdir)/%.texi $(outdir)/$(INFO_IMAGES_DIR).info-images-dir-dep $(outdir)/version.itexi $(outdir)/weblinks.itexi
+$(outdir)/%.info: $(outdir)/%.texi $(outdir)/$(INFO_IMAGES_DIR).info-images-dir-dep $(outdir)/version.itexi $(outdir)/weblinks.itexi | $(OUT_TEXINFO_MANUALS)
ifeq ($(WEB_VERSION),yes)
$(buildscript-dir)/run-and-check "$(MAKEINFO) -I$(src-dir) -I$(outdir) -D web_version --output=$@ $<" "$*.makeinfoweb.log"
else
$(buildscript-dir)/run-and-check "$(MAKEINFO) -I$(src-dir) -I$(outdir) --output=$@ $<" "$*.makeinfo.log"
endif
-$(outdir)/%-big-page.html: $(outdir)/%.texi $(XREF_MAPS_DIR)/%.xref-map $(outdir)/version.itexi $(outdir)/weblinks.itexi
+$(outdir)/%-big-page.html: $(outdir)/%.texi $(XREF_MAPS_DIR)/%.xref-map $(outdir)/version.itexi $(outdir)/weblinks.itexi | $(OUT_TEXINFO_MANUALS)
ifeq ($(WEB_VERSION),yes)
$(buildscript-dir)/run-and-check "DEPTH=$(depth) AJAX_SEARCH=$(AJAX_SEARCH) $(TEXI2HTML) $(TEXI2HTML_FLAGS) -D bigpage -D web_version --output=$@ $<" "$*.bigtexi.log"
else
$(buildscript-dir)/run-and-check "DEPTH=$(depth) AJAX_SEARCH=$(AJAX_SEARCH) $(TEXI2HTML) $(TEXI2HTML_FLAGS) -D bigpage --output=$@ $<" "$*.bigtexi.log"
endif
-$(outdir)/%.html: $(outdir)/%.texi $(XREF_MAPS_DIR)/%.xref-map $(outdir)/version.itexi $(outdir)/weblinks.itexi
+$(outdir)/%.html: $(outdir)/%.texi $(XREF_MAPS_DIR)/%.xref-map $(outdir)/version.itexi $(outdir)/weblinks.itexi | $(OUT_TEXINFO_MANUALS)
$(buildscript-dir)/run-and-check "DEPTH=$(depth) AJAX_SEARCH=$(AJAX_SEARCH) $(TEXI2HTML) $(TEXI2HTML_FLAGS) --output=$@ $<" "$*.texilog.log"
-$(outdir)/%/index.html: $(outdir)/%.texi $(XREF_MAPS_DIR)/%.xref-map $(outdir)/version.itexi $(outdir)/weblinks.itexi $(outdir)/%.html.omf
+$(outdir)/%/index.html: $(outdir)/%.texi $(XREF_MAPS_DIR)/%.xref-map $(outdir)/version.itexi $(outdir)/weblinks.itexi $(outdir)/%.html.omf | $(OUT_TEXINFO_MANUALS)
mkdir -p $(dir $@)
ifeq ($(WEB_VERSION),yes)
$(buildscript-dir)/run-and-check "DEPTH=$(depth)/../ AJAX_SEARCH=$(AJAX_SEARCH) $(TEXI2HTML) $(TEXI2HTML_SPLIT) $(TEXI2HTML_FLAGS) -D web_version --output=$(dir $@) $<" "$*.splittexi.log"
@@ -59,24 +59,21 @@ else
endif
ifneq ($(ISOLANG),)
-$(XREF_MAPS_DIR)/%.$(ISOLANG).xref-map: $(outdir)/%.texi $(XREF_MAPS_DIR)/%.xref-map
+$(XREF_MAPS_DIR)/%.$(ISOLANG).xref-map: $(outdir)/%.texi $(XREF_MAPS_DIR)/%.xref-map | $(OUT_TEXINFO_MANUALS)
$(buildscript-dir)/extract_texi_filenames $(XREF_MAP_FLAGS) -q -o $(XREF_MAPS_DIR) --master-map-file=$(XREF_MAPS_DIR)/$*.xref-map $<
else
-$(XREF_MAPS_DIR)/%.xref-map: $(outdir)/%.texi
+$(XREF_MAPS_DIR)/%.xref-map: $(outdir)/%.texi | $(OUT_TEXINFO_MANUALS)
$(buildscript-dir)/extract_texi_filenames $(XREF_MAP_FLAGS) -q -o $(XREF_MAPS_DIR) $<
endif
-$(outdir)/%.info: %.texi $(outdir)/$(INFO_IMAGES_DIR).info-images-dir-dep $(outdir)/version.itexi $(outdir)/weblinks.itexi
- $(buildscript-dir)/run-and-check "$(MAKEINFO) -I$(src-dir) -I$(outdir) --output=$@ $<" "$*.makeinfo.log"
-
-$(outdir)/%.pdf: $(outdir)/%.texi $(outdir)/version.itexi $(outdir)/%.pdf.omf $(outdir)/weblinks.itexi
+$(outdir)/%.pdf: $(outdir)/%.texi $(outdir)/version.itexi $(outdir)/%.pdf.omf $(outdir)/weblinks.itexi | $(OUT_TEXINFO_MANUALS)
ifeq ($(WEB_VERSION),yes)
$(buildscript-dir)/run-and-check "cd $(outdir); texi2pdf $(TEXI2PDF_FLAGS) -D web_version -I $(abs-src-dir) $(TEXINFO_PAPERSIZE_OPTION) $(<F) < /dev/null" "$*.texi2pdf.log"
else
$(buildscript-dir)/run-and-check "cd $(outdir); texi2pdf $(TEXI2PDF_FLAGS) -I $(abs-src-dir) $(TEXINFO_PAPERSIZE_OPTION) $(<F) < /dev/null" "$*.texi2pdf.log"
endif
-$(outdir)/%.txt: $(outdir)/%.texi $(outdir)/version.itexi $(outdir)/weblinks.itexi
+$(outdir)/%.txt: $(outdir)/%.texi $(outdir)/version.itexi $(outdir)/weblinks.itexi | $(OUT_TEXINFO_MANUALS)
$(buildscript-dir)/run-and-check "$(MAKEINFO) -I$(src-dir) -I$(outdir) --no-split --no-headers --output $@ $<" "$*.makeinfotxt.log"
$(outdir)/%.html.omf: %.texi
diff --git a/stepmake/stepmake/texinfo-targets.make b/stepmake/stepmake/texinfo-targets.make
index fecbb47999..6dbc031de5 100644
--- a/stepmake/stepmake/texinfo-targets.make
+++ b/stepmake/stepmake/texinfo-targets.make
@@ -3,7 +3,7 @@
default: $(INFO_FILES)
ifeq ($(out),www)
-local-WWW-1: $(XREF_MAPS_FILES)
+local-WWW-1: $(OUT_TEXINFO_MANUALS) $(XREF_MAPS_FILES)
endif
local-txt-doc: $(OUTTXT_FILES)