]> git.donarmstrong.com Git - lilypond.git/commitdiff
* scm/lily.scm (lilypond-all): option read-file-list: substitute
authorHan-Wen Nienhuys <hanwen@xs4all.nl>
Sat, 19 Aug 2006 22:00:01 +0000 (22:00 +0000)
committerHan-Wen Nienhuys <hanwen@xs4all.nl>
Sat, 19 Aug 2006 22:00:01 +0000 (22:00 +0000)
commandline args with contains, split by \n.

* scripts/lilypond-book.py (Lilypond_file_snippet.my_system):
write snippet-names file, call with -dread-file-list. Fixes
command limitations on 64-bit systems.

* scripts/lilypond-book.py (main): add --formats=eps for
texinfo/latex.

ChangeLog
lily/lily-guile.cc
lily/lily-parser-scheme.cc
lily/main.cc
scm/lily.scm
scripts/lilypond-book.py

index 6ab95979063c79ac40558146b3f35a478f4a9192..f2746e16ad6479796ec7e40269a6d986db4d205d 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,10 +1,17 @@
 2006-08-19  Han-Wen Nienhuys  <hanwen@lilypond.org>
 
+       * scm/lily.scm (lilypond-all): option read-file-list: substitute
+       commandline args with contains, split by \n.
+
+       * scripts/lilypond-book.py (Lilypond_file_snippet.my_system):
+       write snippet-names file, call with -dread-file-list. Fixes
+       command limitations on 64-bit systems.
+
        * input/regression/stencil-color-rotation.ly: new file.
 
        * lily/include/translator.hh (struct Acknowledge_information):
        revert: don't use Protected_scm in global objects, as GUILE can't
-       handle gc_unprotect from automated destructors.
+       handle gc_unprotect from automated destructors on MacOS X.
  
        * lily/grob.cc (get_print_stencil): use retval.expr() as base for
        color, not the original stencil. Fixes combinations of
index 26d2d30ac8400e46e55fdb4da9adfd51494e6820..f7938cfc210643a57993e34fbaf54e16fef3cc6a 100644 (file)
@@ -131,7 +131,7 @@ ly_scm2string (SCM str)
 {
   assert (scm_is_string (str));
   return string (scm_i_string_chars (str),
-                    (int) scm_i_string_length (str));
+                (int) scm_i_string_length (str));
 }
 
 char *
index 56de47abbd21945a3ff5ba788027ab5a96240dc8..0e844d2bc0ec51053f3f938cb4ac747fbf883af8 100644 (file)
@@ -37,7 +37,7 @@ LY_DEFINE (ly_parse_file, "ly:parse-file",
           "Upon failure, throw @code{ly-file-failed} key.")
 {
   SCM_ASSERT_TYPE (scm_is_string (name), name, SCM_ARG1, __FUNCTION__, "string");
-  char const *file = scm_i_string_chars (name);
+  string file = ly_scm2string (name);
   char const *extensions[] = {"ly", "", 0};
 
   string file_name = global_path.find (file, extensions);
index bfdf01566f0d5ebf239cdb5e2ce244bd7a453e32..ae4c86dd2ae9b8f339eb4ce132f5192f0a52f0e3 100644 (file)
@@ -427,6 +427,7 @@ main_with_guile (void *, int, char **)
       *tail = scm_cons (scm_makfrom0str (arg), SCM_EOL);
       tail = SCM_CDRLOC (*tail);
     }
+  
   delete option_parser;
   option_parser = 0;
 
index 7ed892cc4026b02085efa4f0aa859cfad5ed1ac2..79b060ec7056236d2fcd0ef0c06b0ed3217cef4e 100644 (file)
@@ -42,6 +42,7 @@ similar to chord syntax")
                        "dump GC protection info")
              (show-available-fonts #f
                                    "List  font names available.")
+             (read-file-list #f "Read files to be processed from command line arguments")
              )))
 
 
@@ -390,6 +391,14 @@ The syntax is the same as `define*-public'."
          (exit 0)))))
 
 (define-public (lilypond-all files)
+  (if (ly:get-option 'read-file-list)
+      (set! files
+           (filter (lambda (s)
+                     (> (string-length s) 0))
+                   (apply append
+                          (map (lambda (f) (string-split (ly:gulp-file f) #\nl))
+                               files)))
+           ))
 
   (if (ly:get-option 'show-available-fonts)
       (begin
index ddde74ae97a92f65740a37e0969b69daa9eb3f63..9e2932113ffb46b906104ac96c08422ee7a36795 100644 (file)
@@ -134,6 +134,7 @@ def get_option_parser ():
     p.add_option ('-f', '--format',
                   help=_('''use output format FORMAT (texi [default], texi-html, latex, html)'''),
                   action='store')
+    
     p.add_option ("-I", '--include', help=_('add DIR to include path'),
                   metavar="DIR",
                   action='append', dest='include_path',
@@ -1381,7 +1382,11 @@ def process_snippets (cmd, ly_snippets, texstr_snippets, png_snippets):
             my_system ('latex %s.texstr' % l)
 
     if ly_names:
-        my_system (string.join ([cmd, 'snippet-map.ly'] + ly_names))
+        open ('snippet-names', 'w').write ('\n'.join (['snippet-map.ly']
+                                                      + ly_names))
+        
+        my_system (string.join ([cmd, 'snippet-names']))
+
 
 LATEX_INSPECTION_DOCUMENT = r'''
 \nonstopmode
@@ -1716,9 +1721,13 @@ def main ():
         and global_options.create_pdf):
         global_options.process_cmd += "--pdf  -deps-font-include -dgs-font-load "
 
+        
     
     if global_options.verbose:
         global_options.process_cmd += " --verbose "
+
+    global_options.process_cmd += " -dread-file-list "
+
     identify ()
 
     try: