X-Git-Url: https://git.donarmstrong.com/?a=blobdiff_plain;f=scripts%2Fbuild%2Fmf-to-table.py;h=f191d0aa8fcc3a0941e01f8c4f829d5cd90a8e8f;hb=32a34dcef0c0041c6d62677487a380b5c8b85712;hp=3f7b3cbb2fc88ff969711bcb2a478e5dee09df09;hpb=f41973ff763d5972a85995b6d40c864281ec6714;p=lilypond.git diff --git a/scripts/build/mf-to-table.py b/scripts/build/mf-to-table.py index 3f7b3cbb2f..f191d0aa8f 100644 --- a/scripts/build/mf-to-table.py +++ b/scripts/build/mf-to-table.py @@ -4,7 +4,7 @@ # This file is part of LilyPond, the GNU music typesetter. # -# Copyright (C) 1997--2011 Han-Wen Nienhuys +# Copyright (C) 1997--2012 Han-Wen Nienhuys # # 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,7 +27,7 @@ import time def read_log_file (fn): str = open (fn).read () - str = re.sub ('\n', '', str) + str = re.sub ('[\n\r]', '', str) str = re.sub ('[\t ]+', ' ', str) deps = [] @@ -61,14 +61,20 @@ def parse_logfile (fn): } group = '' - for l in autolines: + for i, l in enumerate(autolines): tags = l.split ('@:') if tags[0] == 'group': group = tags[1] elif tags[0] == 'puorg': group = '' elif tags[0] == 'char': - name = tags[9] + try: + name = tags[9] + except IndexError: + print 'Error in mf-to-table while processing file', fn + print 'Index 9 >', len(tags)-1, 'on line', i + print l + raise if group: name = group + '.' + name @@ -242,8 +248,12 @@ for filenm in files: enc_name = 'FetaEncoding' if re.search ('parmesan', filenm): enc_name = 'ParmesanEncoding' + elif re.search ('parmesan-noteheads', filenm): + enc_name = 'ParmesanNoteheadsEncoding' elif re.search ('feta-noteheads', filenm): enc_name = 'FetaNoteheadsEncoding' + elif re.search ('feta-flags', filenm): + enc_name = 'FetaFlagsEncoding' elif re.search ('feta-brace', filenm): enc_name = 'FetaBraceEncoding' elif re.search ('feta-alphabet', filenm):