X-Git-Url: https://git.donarmstrong.com/?a=blobdiff_plain;ds=sidebyside;f=scripts%2Flilypond-book.py;h=5b9c0d738f9b9669ee43eba424060a7b9a3cb423;hb=e8af8e814eab52b8080f18f78bad7bade87c1c10;hp=dd495fc7509e213d10fbe49c3153aefc5e4e9489;hpb=f9214bac21e9926dc3248416f58190c98c4167a9;p=lilypond.git diff --git a/scripts/lilypond-book.py b/scripts/lilypond-book.py index dd495fc750..5b9c0d738f 100644 --- a/scripts/lilypond-book.py +++ b/scripts/lilypond-book.py @@ -37,23 +37,9 @@ import sys import re import md5 -################ -# RELOCATION -################ - - -for d in ['@lilypond_datadir@', - '@lilypond_libdir@']: - sys.path.insert (0, os.path.join (d, 'python')) - -# dynamic relocation, for GUB binaries. -bindir = os.path.abspath (os.path.split (sys.argv[0])[0]) - -os.environ['PATH'] = bindir + os.pathsep + os.environ['PATH'] -for p in ['share', 'lib']: - datadir = os.path.abspath (bindir + '/../%s/lilypond/current/python/' % p) - sys.path.insert (0, datadir) - +""" +@relocate-preamble@ +""" import lilylib as ly import fontextract @@ -115,7 +101,7 @@ def warranty (): %s %s -''' % ( _ ('Copyright (c) %s by') % '2001--2006', +''' % ( _ ('Copyright (c) %s by') % '2001--2007', ' '.join (authors), _ ("Distributed under terms of the GNU General Public License."), _ ("It comes with NO WARRANTY."))) @@ -154,7 +140,7 @@ def get_option_parser (): p.add_option ('-P', '--process', metavar=_ ("COMMAND"), help = _ ("process ly_files using COMMAND FILE..."), action='store', - dest='process_cmd', default='lilypond -b eps') + dest='process_cmd', default='lilypond -dbackend=eps') p.add_option ('--pdf', action="store_true", dest="create_pdf", @@ -690,17 +676,14 @@ if 0: PREAMBLE_LY = '''%%%% Generated by %(program_name)s %%%% Options: [%(option_string)s] \\include "lilypond-book-preamble.ly" -%(preamble_string)s - - - - %% **************************************************************** %% Start cut-&-pastable-section %% **************************************************************** +%(preamble_string)s + \paper { #(define dump-extents #t) %(font_dump_setting)s