>From 7356d051e176a9e9dc99d0e7f219e9bbd1527777 Mon Sep 17 00:00:00 2001 From: Patrick McCarty Date: Thu, 20 Aug 2009 02:34:42 -0700 Subject: [PATCH] Fix #832 --- scm/backend-library.scm | 26 +++++++++++++------------- 1 files changed, 13 insertions(+), 13 deletions(-) diff --git a/scm/backend-library.scm b/scm/backend-library.scm index 3a4ccab..ed10f32 100644 --- a/scm/backend-library.scm +++ b/scm/backend-library.scm @@ -1,11 +1,11 @@ ;;;; backend-library.scm -- helpers for the backends. ;;;; ;;;; source file of the GNU LilyPond music typesetter -;;;; +;;;; ;;;; (c) 2005--2009 Jan Nieuwenhuizen ;;;; Han-Wen Nienhuys -;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; +;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ;; backend helpers. (use-modules (scm ps-to-png) @@ -27,12 +27,12 @@ (if (pair? rest) (system-with-env silenced (car rest)) (system silenced))) - + (if (> status 0) (begin (ly:message (_ "`~a' failed (~a)") command status) (ly:progress "\n") - ;; hmmm. what's the best failure option? + ;; hmmm. what's the best failure option? (throw 'ly-file-failed))))) (define-public (system-with-env cmd env) @@ -40,20 +40,20 @@ "Execute CMD in fork, with ENV (a list of strings) as the environment" (let* ;; laziness: should use execle? - + ((pid (primitive-fork))) (if (= 0 pid) ;; child (begin (environ env) (system cmd)) - + ;; parent (cdr (waitpid pid))))) (define-public (sanitize-command-option str) "Kill dubious shell quoting" - + (string-append "\"" (regexp-substitute/global #f "[^-_ 0-9,.a-zA-Z'\"\\]" str 'pre 'post) @@ -70,10 +70,10 @@ (helper path names))) (define-public (search-gs) - + ;; must be sure that we don't catch stuff from old GUBs. (search-executable '("gs"))) - + (define-public (postscript->pdf paper-width paper-height name) (let* ((pdf-name (string-append (dir-basename name ".ps" ".eps") @@ -85,8 +85,8 @@ -dDEVICEHEIGHTPOINTS=~$" paper-width paper-height))) - (cmd (simple-format #f - "~a\ + (cmd (ly:format +"~a\ ~a\ ~a\ ~a\ @@ -95,9 +95,9 @@ -dBATCH\ -r1200\ -sDEVICE=pdfwrite\ - -sOutputFile=~S\ + -sOutputFile=~a\ -c .setpdfwrite\ - -f ~S\ + -f ~a\ " (search-gs) (if (ly:get-option 'verbose) "" "-q") -- 1.6.4