def source_links_replace (m, source_val):
return 'href="' + os.path.join (source_val, m.group (1)) + '"'
-splitted_docs_re = re.compile ('(input/lsr/out-www/snippets|Documentation/user/out-www/(lilypond|music-glossary|lilypond-program|lilypond-learning))/')
+splitted_docs_re = re.compile ('(input/lsr/out-www/lilypond-snippets|Documentation/user/out-www/(lilypond|music-glossary|lilypond-program|lilypond-learning))/')
snippets_ref_re = re.compile (r'href="(\.\./)?lilypond-snippets')
# This function avoids creating symlinks for splitted HTML manuals
# Get rid of symlinks in GNUmakefile.in (local-WWW-post)
# this also fixes missing PNGs only present in translated docs
-def _urls (s, prefix):
+def hack_urls (s, prefix):
if splitted_docs_re.match (prefix):
s = re.sub ('(href|src)="(lily-.*?|.*?[.]png)"', '\\1="../\\2"', s)
in_f.close()
s = re.sub ('%', '%%', s)
- s = replace_symlinks_urls (s, prefix)
+ s = hack_urls (s, prefix)
s = add_header (s)
### add footer
LOCALSTEPMAKE_TEMPLATES=lilypond ly
EXTRA_DIST_FILES += README $(call src-wildcard,*.snippet-list)
+ifneq ($(out),)
MAIN_INFO_DOC = lilypond-snippets
INFO_DOCS = lilypond-snippets
INFO_FILES = $(INFO_DOCS:%=$(outdir)/%.info)
INFO_IMAGES_DIR = lilypond-snippets
DEST_INFO_IMAGES_SUBDIR = input/lsr
+endif
+
+default:
include $(depth)/make/stepmake.make
info: $(INFO_FILES)
ifneq ($(out),www)
-# cancel install-info target
+# cancel install-info target and $(INFO_FILES) 'default' target
# (there is no lilypond-snippets.info without images)
local-install-info:
+
+$(INFO_FILES):
true
endif
uninstall-info:
$(INFO_INSTALL_COMMAND) local-uninstall
+ifeq ($(INFO_FILES),)
+local-install-info:
+local-uninstall-info:
+
+else # $(INFO_FILES) non empty
# There are two modes for info: with and without images.
ifeq ($(out),www)
endif # out!=www
+endif # $(INFO_FILES) non empty
TEXINFO_ALL_MENUS_UPDATE_EL ='\
(let ((error nil)\