CVSROOT:        /cvsroot/lilypond
Module name:    lilypond
Branch:         
Changes by:     Jan Nieuwenhuizen <[EMAIL PROTECTED]>   05/05/06 08:23:23

Modified files:
        mf             : GNUmakefile 
        buildscripts   : substitute-encoding.py 
        .              : ChangeLog 

Log message:
        * mf/GNUmakefile (MFTRACE_FLAGS):
        * buildscripts/substitute-encoding.py (outdir): Build fix: pass
        outdir as option (WAS: hardcoded).

CVSWeb URLs:
http://savannah.gnu.org/cgi-bin/viewcvs/lilypond/lilypond/mf/GNUmakefile.diff?tr1=1.162&tr2=1.163&r1=text&r2=text
http://savannah.gnu.org/cgi-bin/viewcvs/lilypond/lilypond/buildscripts/substitute-encoding.py.diff?tr1=1.1&tr2=1.2&r1=text&r2=text
http://savannah.gnu.org/cgi-bin/viewcvs/lilypond/lilypond/ChangeLog.diff?tr1=1.3556&tr2=1.3557&r1=text&r2=text

Patches:
Index: lilypond/ChangeLog
diff -u lilypond/ChangeLog:1.3556 lilypond/ChangeLog:1.3557
--- lilypond/ChangeLog:1.3556   Fri May  6 00:03:42 2005
+++ lilypond/ChangeLog  Fri May  6 08:23:23 2005
@@ -1,3 +1,9 @@
+2005-05-06  Jan Nieuwenhuizen  <[EMAIL PROTECTED]>
+
+       * mf/GNUmakefile (MFTRACE_FLAGS):
+       * buildscripts/substitute-encoding.py (outdir): Build fix: pass
+       outdir as option (WAS: hardcoded).
+
 2005-05-06  Han-Wen Nienhuys  <[EMAIL PROTECTED]>
 
        * THANKS: add Hans Forbrich.
Index: lilypond/buildscripts/substitute-encoding.py
diff -u lilypond/buildscripts/substitute-encoding.py:1.1 
lilypond/buildscripts/substitute-encoding.py:1.2
--- lilypond/buildscripts/substitute-encoding.py:1.1    Tue May  3 14:25:10 2005
+++ lilypond/buildscripts/substitute-encoding.py        Fri May  6 08:23:23 2005
@@ -5,12 +5,21 @@
 #
 # http://bugs.ghostscript.com/show_bug.cgi?id=688017
 
+import getopt
+import os
+import re
 import string
 import sys
-import re
-import os
 
-filename = sys.argv[1]
+outdir = 'out'
+(options, files) = getopt.getopt (sys.argv[1:], 'o', ['outdir='])
+for opt in options:
+       o = opt[0]
+       a = opt[1]
+       if o == '--outdir' or o == '-o':
+               outdir = a
+
+filename = files[0]
 def get_glyph_names (enc_name):
        enc_str = open (enc_name).read ()
        glyphs = []
@@ -26,9 +35,9 @@
        return glyphs
 
 if re.search ('mmental', filename):
-       glyph_names = (get_glyph_names ('out/feta20.enc') +
-                      get_glyph_names ('out/feta-alphabet20.enc') +
-                      get_glyph_names ('out/parmesan20.enc'))
+       glyph_names = (get_glyph_names ('%(outdir)s/feta20.enc' % vars ())
+                      + get_glyph_names ('%(outdir)s/feta-alphabet20.enc' % 
vars ())
+                      + get_glyph_names ('%(outdir)s/parmesan20.enc' % vars 
()))
 
        str = open (filename).read ()
        os.rename (filename, filename + "~")
@@ -46,6 +55,3 @@
                      str)
 
        open (filename, 'w').write (str)
-
-
-
Index: lilypond/mf/GNUmakefile
diff -u lilypond/mf/GNUmakefile:1.162 lilypond/mf/GNUmakefile:1.163
--- lilypond/mf/GNUmakefile:1.162       Tue May  3 16:51:02 2005
+++ lilypond/mf/GNUmakefile     Fri May  6 08:23:23 2005
@@ -58,7 +58,7 @@
 
 $(outdir)/$(PFA_PREFIX)%.pfa $(outdir)/%.otf $(outdir)/%.svg: $(outdir)/%.pe
        (cd $(outdir) && $(FONTFORGE) -script $(notdir $<))
-       $(PYTHON) $(buildscript-dir)/substitute-encoding.py $@
+       $(PYTHON) $(buildscript-dir)/substitute-encoding.py --outdir=$(outdir) 
$@
        -rm $(outdir)/*.scale.pfa
 
 # ugh, this does not work


_______________________________________________
Lilypond-cvs mailing list
Lilypond-cvs@gnu.org
http://lists.gnu.org/mailman/listinfo/lilypond-cvs

Reply via email to