]> git.donarmstrong.com Git - lilypond.git/blobdiff - stepmake/stepmake/texinfo-vars.make
Build: Only sed through an input file if it exists.
[lilypond.git] / stepmake / stepmake / texinfo-vars.make
index b98b1ccbdaf1f1e3cd344c09c2de335947231ec9..c370990413aa65b4da9a4ac74954a80dc9ddb93e 100644 (file)
@@ -20,7 +20,7 @@ $(firstword \
 # Recursively scan the file $(1) for @include, search for included files
 # within the texinfo include dirs, and return all dependencies.
 scan-texi = \
-$(foreach f, $(shell sed -ne "/^@include[[:space:]]/s/@include//p" $(1)), \
+$(foreach f, $(shell test -f $(1) && sed -ne "/^@include[[:space:]]/s/@include//p" $(1)), \
        $(call find-texi,$(f)) \
        $(call scan-texi,$(call find-texi,$(f))) \
 )
@@ -37,10 +37,14 @@ MAKEINFO_FLAGS += --enable-encoding --error-limit=0 $(DOCUMENTATION_INCLUDES)
 MAKEINFO = LANG= $(MAKEINFO_PROGRAM) $(MAKEINFO_FLAGS)
 
 # texi2html xref map files
-# FIXME: duplicated in stepake/texinfo-vars.make make/doc-i18n-root-vars.make
 XREF_MAPS_DIR = $(top-build-dir)/$(outdir)/xref-maps
+ifneq ($(ISOLANG),)
+XREF_MAPS_FILES += $(TEXI_FILES:%.texi=$(XREF_MAPS_DIR)/%.$(ISOLANG).xref-map) \
+ $(TELY_FILES:%.tely=$(XREF_MAPS_DIR)/%.$(ISOLANG).xref-map)
+else
 XREF_MAPS_FILES += $(TEXI_FILES:%.texi=$(XREF_MAPS_DIR)/%.xref-map) \
  $(TELY_FILES:%.tely=$(XREF_MAPS_DIR)/%.xref-map)
+endif
 XREF_MAP_FLAGS += -I $(outdir) -I $(src-dir) $(DOCUMENTATION_INCLUDES)
 
 ###########