]> git.donarmstrong.com Git - lilypond.git/commitdiff
Fix changes resulting from Snippets compilation in Info
authorJohn Mandereau <john.mandereau@gmail.com>
Fri, 29 Feb 2008 21:15:51 +0000 (22:15 +0100)
committerJohn Mandereau <john.mandereau@gmail.com>
Fri, 29 Feb 2008 21:15:51 +0000 (22:15 +0100)
buildscripts/add_html_footer.py
input/lsr/GNUmakefile
stepmake/stepmake/texinfo-targets.make

index da827c130164de217acb3ae553191f28c6d4d287..7f30c94edca2ae4555372b7875a9906f6f71926d 100644 (file)
@@ -87,7 +87,7 @@ def build_pages_dict (filelist):
 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')
 
@@ -95,7 +95,7 @@ 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)
 
@@ -268,7 +268,7 @@ def add_html_footer (translation,
             in_f.close()
 
             s = re.sub ('%', '%%', s)
-            s = replace_symlinks_urls (s, prefix)
+            s = hack_urls (s, prefix)
             s = add_header (s)
 
             ### add footer
index ec25f7310d5bda726fa87686ea9c1eba92bbd6b5..16946ea380e995a088f23360793a473d12894e03 100644 (file)
@@ -6,11 +6,15 @@ STEPMAKE_TEMPLATES=documentation texinfo tex
 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
 
@@ -25,9 +29,11 @@ $(outdir)/lilypond-snippets.texi: $(GENERATED_ITELY_FILES)
 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
 
index 8f421dfedcc9d52496cb51d943ab5faa58369427..488b81f24bac9423cce410b380e337f505f694e7 100644 (file)
@@ -20,6 +20,11 @@ install-info: $(INFO_FILES)
 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)
 
@@ -87,6 +92,7 @@ endif # installing into standard /usr/* root# installing into /usr/...
 
 endif # out!=www
 
+endif # $(INFO_FILES) non empty
 
 TEXINFO_ALL_MENUS_UPDATE_EL ='\
   (let ((error nil)\