]> 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 cbe6d23e4bae71023f0a525a66ff1f69600ef8c4..17f822247b763286137855573b7bbcc1b90ea658 100644 (file)
@@ -1,6 +1,6 @@
 ;;;; This file is part of LilyPond, the GNU music typesetter.
 ;;;;
-;;;; Copyright (C) 2005--2010 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
@@ -27,6 +27,8 @@
  (lily)
  )
 
+;; FIXME: use backend-library for duplicates and stubs; lilypond-ps2png.scm is no more
+
 (define-public _ gettext)
 
 (define PLATFORM
          (output-file (if multi-page? pngn png1))
 
          (gs-variable-options
-           ;; ps-page-count returns 0 for EPS files
-           (if (zero? page-count)
+           (if (string-suffix-ci? ".eps" ps-name)
                "-dEPSCrop"
                (format #f "-dDEVICEWIDTHPOINTS=~,2f -dDEVICEHEIGHTPOINTS=~,2f"
                        page-width page-height)))