]> git.donarmstrong.com Git - lilypond.git/blobdiff - scripts/build/lys-to-tely.py
Merge remote-tracking branch 'origin/translation' into staging
[lilypond.git] / scripts / build / lys-to-tely.py
index a3bc4b576bdc8e08f4bc9ff0f9e2dbbe42147c53..ad0f7a6aa90883909cb34b58cbe7271cd7a7a59e 100644 (file)
@@ -53,6 +53,11 @@ author = "Han-Wen Nienhuys and Jan Nieuwenhuizen"
 input_filename = ""
 glob_input = ""
 template = '''\input texinfo
+
+@c This file was autogenerated
+@c     from: %s
+@c     by:   %s
+
 @setfilename %%(name)s.info
 @settitle %%(title)s
 
@@ -63,6 +68,14 @@ template = '''\input texinfo
 
 @finalout @c we do not want black boxes.
 
+@c Trick to use with proper font mappings the same NCSB fonts as
+@c LilyPond instead of those provided by TeX distribution
+@tex
+\\ifpdf
+  \\pdfmapfile{=lilypond.map}
+\\fi
+@end tex
+
 @c fool ls-latex
 @ignore
 @author %%(author)s
@@ -75,7 +88,7 @@ template = '''\input texinfo
 %s
 
 @bye
-''' % include_snippets
+''' % (", ".join(files), sys.argv[0], include_snippets)
 
 for opt in options:
     o = opt[0]
@@ -163,12 +176,10 @@ if files:
     s = "\n".join (map (name2line, files))
     s = template.replace (include_snippets, s, 1)
     f = "%s/%s" % (dir, name)
-    sys.stderr.write ("%s: writing %s..." % (program_name, f))
     h = open (f, "w")
     h.write (s)
     h.close ()
-    sys.stderr.write ('\n')
 else:
     # not Unix philosophy, but hey, at least we notice when
     # we don't distribute any .ly files.
-    sys.stderr.write ("No files specified. Doing nothing")
+    sys.stderr.write ("No files specified. Doing nothing. Use -h to display usage.")