]> git.donarmstrong.com Git - lilypond.git/blobdiff - scm/ps-to-png.scm
Use g_spawn_sync () instead of system (). Fixes #1429.
[lilypond.git] / scm / ps-to-png.scm
index 529d405d9a44d63b63119a6cbd389306000f4a4b..17f822247b763286137855573b7bbcc1b90ea658 100644 (file)
@@ -1,6 +1,6 @@
 ;;;; This file is part of LilyPond, the GNU music typesetter.
 ;;;;
-;;;; Copyright (C) 2005--2009 Jan Nieuwenhuizen <janneke@gnu.org>
+;;;; Copyright (C) 2005--2011 Jan Nieuwenhuizen <janneke@gnu.org>
 ;;;;
 ;;;; LilyPond is free software: you can redistribute it and/or modify
 ;;;; it under the terms of the GNU General Public License as published by
  (lily)
  )
 
-;; gettext wrapper for guile < 1.7.2
-(if (defined? 'gettext)
-    (define-public _ gettext)
-    (define-public (_ x) x))
+;; FIXME: use backend-library for duplicates and stubs; lilypond-ps2png.scm is no more
+
+(define-public _ gettext)
 
 (define PLATFORM
   (string->symbol
          (output-file (if multi-page? pngn png1))
 
          (gs-variable-options
-          (if multi-page?
-              (format #f "-dDEVICEWIDTHPOINTS=~,2f -dDEVICEHEIGHTPOINTS=~,2f"
-                      page-width page-height)
-              "-dEPSCrop"))
+           (if (string-suffix-ci? ".eps" ps-name)
+               "-dEPSCrop"
+               (format #f "-dDEVICEWIDTHPOINTS=~,2f -dDEVICEHEIGHTPOINTS=~,2f"
+                       page-width page-height)))
          (cmd (ly:format "~a\
  ~a\
  ~a\