]> git.donarmstrong.com Git - lilypond.git/commitdiff
(ly:system): add > /dev/null 2>&1
authorHan-Wen Nienhuys <hanwen@xs4all.nl>
Sat, 6 Nov 2004 00:18:04 +0000 (00:18 +0000)
committerHan-Wen Nienhuys <hanwen@xs4all.nl>
Sat, 6 Nov 2004 00:18:04 +0000 (00:18 +0000)
ChangeLog
THANKS
mf/GNUmakefile
scm/framework-tex.scm
scm/lily.scm

index fed04798edffa220d8831c22b021ab365cb38e2a..f11faf1974dff3dcb9aaf8fee36cb3d08bde901f 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,7 @@
 2004-11-06  Han-Wen Nienhuys  <hanwen@xs4all.nl>
 
+       * scm/lily.scm (ly:system): add > /dev/null 2>&1 
+
        * lily/recording-group-engraver.cc (derived_mark): mark
        now_events_. (backportme)
 
diff --git a/THANKS b/THANKS
index a8fed5da0b84ffc0a9d4283aac65fb1601469e68..b748ab65d2dd067922fb85c40cdf23ca452c4304 100644 (file)
--- a/THANKS
+++ b/THANKS
@@ -19,7 +19,7 @@ Heikki Junes
 BUG HUNTERS/SUGGESTIONS
 
 Fernando Pablo Lopez-Lezcano
-
+Jack O'Quin
 
 Release 2.4
 ***********
index 914f20830a1eecea0ff058783e71932dea75f103..802c03f6b77faf36abed867428d560639c266951 100644 (file)
@@ -125,7 +125,6 @@ get-deb-pfa: $(outdir)/$(debian-package)
        rm -rf $(outdir)/./usr
        ar p $< data.tar.gz | \
                tar -C $(outdir) -zvxf - '*.pfa'
-       touch $(addprefix $(outdir)/, $(addsuffix .bla,$(SAUTER_FONTS)))
        cp `find $(outdir)/usr/ -name '*.pfa'` $(outdir)/
 
 
@@ -136,7 +135,6 @@ $(outdir)/$(redhat-package):
 get-rpm-pfa: $(outdir)/$(redhat-package)
        cd $(outdir) ; rm -rf usr/ # (root alert!) 
        cd $(outdir) ; rpm2cpio $(redhat-package) | cpio -uid '*.pfa'
-       touch $(addprefix $(outdir)/, $(addsuffix .bla,$(SAUTER_FONTS)))
        cp `find $(outdir)/usr/ -name '*.pfa'` $(outdir)/
 
 # change this dependency 
index f068fff9d5ad893b2c2004d5fc47f1103b6413b7..11083657aa684bf1b41693df6a1fd6b591d7c412 100644 (file)
         (ly:get-option 'resolution))
      (string-append (basename name ".tex") ".ps"))))
 
+
+;;
+;; ugh  -   double check this. We are leaking
+;; untrusted (user-settable) info to a command-line 
+;;
 (define-public (convert-to-ps book name)
   (let* ((paper (ly:paper-book-paper book))
         (preview? (string-contains name ".preview"))
                             "  -u+ec-mftrace.map -u+lilypond.map -Ppdf "
                             base
 
-                            (if (ly:get-option 'verbose)
-                                " "
-                                " 2>&1 1>& /dev/null "))))
+                            )))
 
-    (if (ly:get-option 'verbose)
-       (begin 
-         (newline (current-error-port))
-         (format (current-error-port) (_ "Invoking ~S") cmd)
-         (newline (current-error-port)))
+    (if (not (ly:get-option 'verbose))
        (begin
          (format (current-error-port) (_ "Converting to `~a.ps'...") base)
          (newline (current-error-port))))
         (base (basename name ".tex"))
         (cmd (string-append
               "latex \\\\nonstopmode \\\\input " name
-              (if (ly:get-option 'verbose)
-                  " "
-                  " 2>&1 1>& /dev/null "))))
+              )))
     (setenv "extra_mem_top" (number->string (max curr-extra-mem 1024000)))
-    (if (ly:get-option 'verbose)
-       (begin 
-         (newline (current-error-port))
-         (format (current-error-port) (_ "Invoking ~S") cmd)
-         (newline (current-error-port)))
+    (if (not (ly:get-option 'verbose))
        (begin
          (format (current-error-port) (_ "Converting to `~a.dvi'...") base)
          (newline (current-error-port))))
index 82bbfaa384fe4c009b14d9322f1a4f4552abcb96..a8117bd18ac97002bcdf19cedacb792f5750034c 100644 (file)
@@ -563,14 +563,26 @@ possibly turned off."
 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; 
 
 (define-public (ly:system command)
-  (let* ((status 0))
+  (let*
+      ((status 0)
+
+       (silenced
+       (string-append command (if (ly:get-option 'verbose)
+                                ""
+                                " > /dev/null 2>&1 "))))
+    
     (if (ly:get-option 'verbose)
        (format  (current-error-port) (_ "Invoking `~a'...\n") command))
-    (set! status (system command))
+    
+    (set! status (system silenced))
     (if (> status 0)
        (format (current-error-port) (_ "Error invoking `~a'. Return value ~a")
-                        command status))))
+               silenced status))))
 
+;;
+;; ugh  -   double check this. We are leaking
+;; untrusted (user-settable) info to a command-line 
+;;
 (define-public (postscript->pdf papersizename name)
   (let* ((cmd (string-append "ps2pdf -sPAPERSIZE=" papersizename " " name))
         (output-name
@@ -578,6 +590,7 @@ possibly turned off."
     (format (current-error-port) (_ "Converting to `~a'...") output-name)
     (ly:system cmd)))
 
+
 (define-public (postscript->png resolution name)
   (let
       ((cmd (string-append