+2006-06-06 Jan Nieuwenhuizen <janneke@gnu.org>
+
+ * scripts/lilypond-book.py (process_snippets): Argument fix.
+
+ * SConstruct:
+ * buildscripts/builder.py:
+ * lily/SConscript:
+ * mf/SConscript:
+ * Documentation/user/SConscript: More SCons fixes.
+
+2006-06-03 Jan Nieuwenhuizen <janneke@gnu.org>
+
+ * lily/font-config.cc (init_fontconfig): Only initialize if
+ global cache_file is found.
+
2006-06-06 Erik Sandberg <mandolaerik@gmail.com>
* ly/music-functions-init.ly: Updated \overrideProperty to use the
import os
import string
-Import ('env', 'base_glob')
+Import ('env', 'base_glob', 'src_glob')
tely = base_glob ('*.tely')
-png = base_glob ('*.png')
+png = src_glob ('*.png') + map (env.EPS2PNG, base_glob ('*.eps'))
# We need lily and mf to build these.
env.Depends ('lilypond.texi', ['#/lily', '#/mf', '#/python'])
env.Depends ('lilypond.texi', 'lilypond-internals.texi')
-eps = map (env.PNG2EPS, png)
-env.Depends ('lilypond.texi', eps)
+eps = src_glob ('*.eps') + map (env.PNG2EPS, base_glob ('*.png'))
+env.Depends ('lilypond.texi', eps + png)
+lilypond_book_flags = '''--format=$LILYPOND_BOOK_FORMAT --process="lilypond -I$srcdir/input/test $__verbose --backend=eps --formats=ps,png --header=texidoc -dinternal-type-checking -ddump-signatures -danti-alias-factor=2 -dgs-font-load" '''
e = env.Copy (
- LILYPOND_BOOK_FLAGS = '''--process="lilypond --backend=eps --formats=ps,png --header=texidoc -I#/input/test -e '(ly:set-option (quote internal-type-checking) \#t)'"''',
+# LILYPOND_BOOK_FLAGS = '''--process="lilypond --backend=eps --formats=ps,png --header=texidoc -I#/input/test -e '(ly:set-option (quote internal-type-checking) \#t)'"''',
+ LILYPOND_BOOK_FLAGS = lilypond_book_flags,
__verbose = ' --verbose',
GENERATE_DOCUMENTATION = '$srcdir/ly/generate-documentation',
+ ## TEXI2DVI_FLAGS = ['-I#Documentation/user'],
)
e.Command ('lilypond-internals.texi', ['#/lily', '#/mf', '#/python'],
BoolOption ('static', 'build static libraries',
1),
BoolOption ('gui', 'build with GNOME backend (EXPERIMENTAL)',
- 1),
+ 0),
BoolOption ('verbose', 'run commands with verbose flag',
0),
BoolOption ('checksums', 'use checksums instead of timestamps',
def configure (target, source, env):
- vre = re.compile ('^.*[^-.0-9]([0-9][0-9]*\.[0-9]([.0-9]*[0-9])*).*$',
+ dre = re.compile ('\n(200[0-9]{5})')
+ vre = re.compile ('.*?\n[^-.0-9]*([0-9][0-9]*\.[0-9]([.0-9]*[0-9])*)',
re.DOTALL)
def get_version (program):
command = '(pkg-config --modversion %(program)s || %(program)s --version || %(program)s -V) 2>&1' % vars ()
output = pipe.read ()
if pipe.close ():
return None
- v = re.sub (vre, '\\1', output)
+ splits = re.sub ('^|\s', '\n', output)
+ date_hack = re.sub (dre, '\n0.0.\\1', splits)
+ m = re.match (vre, date_hack)
+ v = m.group (1)
if v[-1] == '\n':
v = v[:-1]
return string.split (v, '.')
test_program (optional, 'bison', '1.25', 'Bison -- parser generator',
'bison')
test_program (optional, 'dvips', '0.0', 'Dvips', 'tetex-bin')
-# test_program (optional, 'fontforge', '0.0.20041224', 'FontForge',
-# 'fontforge')
+ test_program (optional, 'fontforge', '0.0.20050624', 'FontForge',
+ 'fontforge')
test_program (optional, 'flex', '0.0', 'Flex -- lexer generator',
'flex')
test_program (optional, 'guile', '1.6', 'GUILE scheme', 'guile')
- test_program (optional, 'gs', '8.14',
+ test_program (optional, 'gs', '8.15',
'Ghostscript PostScript interpreter',
'gs or gs-afpl or gs-esp or gs-gpl')
- test_program (optional, 'mftrace', '1.1.0', 'Metafont tracing Type1',
+ test_program (optional, 'mftrace', '1.1.19', 'Metafont tracing Type1',
'mftrace')
test_program (optional, 'makeinfo', '4.7', 'Makeinfo tool', 'texinfo')
test_program (optional, 'perl', '4.0',
context.Result (ret)
return ret
- def CheckLibkpathseaSo (context):
- saveCFLAGS = []
- if context.env.has_key ('CFLAGS'):
- saveCFLAGS = context.env['CFLAGS']
- CFLAGS_shared_no_debugging = filter (lambda x: x != '-g',
- saveCFLAGS)\
- + ['-shared']
- # FIXME: how does this work, with scons
- context.env.Replace (CFLAGS = CFLAGS_shared_no_debugging)
- #context.env.Replace (CFLAGS = '')
- #context.env.Append (CFLAGS = ['-shared'])
- context.Message ('Checking for libkpathsea... ')
- ret = conf.TryLink ('''#include <kpathsea/kpathsea.h>
- int main ()
- {
- kpse_var_expand ("\$TEXMF");
- return 0;
- }
- ''', '.c')
- context.env.Replace (CFLAGS = saveCFLAGS)
- # FIXME: this prints 'ok' already
- context.Result (ret)
- if not ret:
- return 0
-
- sys.stdout.write ('Checking for libkpathsea.so... ')
- testfile = str (context.sconf.lastTarget)
- shared_size = os.path.getsize (testfile)
- ret = shared_size < 40000
- if ret:
- print 'ok'
- else:
- print 'no'
- return ret
-
conf = Configure (env, custom_tests = { 'CheckYYCurrentBuffer'
- : CheckYYCurrentBuffer,
- 'CheckLibkpathseaSo'
- : CheckLibkpathseaSo })
+ : CheckYYCurrentBuffer })
defines = {
'DIRSEP' : "'%s'" % os.sep,
else:
env.Append (CPPPATH = [PYTHON_INCLUDE])
- headers = ('sys/stat.h', 'assert.h', 'kpathsea/kpathsea.h', 'libio.h',
- 'Python.h')
+ headers = ('assert.h', 'grp.h', 'libio.h', 'pwd.h',
+ 'sys/stat.h', 'utf8/wchar.h', 'wchar.h', 'Python.h')
for i in headers:
if conf.CheckCHeader (i):
key = re.sub ('[./]', '_', 'HAVE_' + string.upper (i))
key = re.sub ('[./]', '_', 'HAVE_' + string.upper (i))
conf.env['DEFINES'][key] = 1
- functions = ('fopencookie', 'funopen',
- 'gettext', 'isinf', 'memmem', 'snprintf', 'vsnprintf')
+ functions = ('chroot', 'fopencookie', 'funopen',
+ 'gettext', 'isinf',
+ 'mbrtowc', 'memmem', 'snprintf', 'vsnprintf', 'wcrtomb')
for i in functions:
if 0 or conf.CheckFunc (i):
key = re.sub ('[./]', '_', 'HAVE_' + string.upper (i))
if conf.CheckYYCurrentBuffer ():
conf.env['DEFINES']['HAVE_FLEXLEXER_YY_CURRENT_BUFFER'] = 1
- if conf.CheckLibkpathseaSo ():
- conf.env['DEFINES']['HAVE_LIBKPATHSEA_SO'] = '1'
-
if conf.CheckLib ('dl'):
pass
- if conf.CheckLib ('kpathsea'):
- conf.env['DEFINES']['KPATHSEA'] = 1
-
- # huh?
- if conf.CheckLib ('kpathsea', 'kpse_find_file'):
- conf.env['DEFINES']['HAVE_KPSE_FIND_FILE'] = '1'
- if conf.CheckLib ('kpathsea', 'kpse_find_tfm'):
- conf.env['DEFINES']['HAVE_KPSE_FIND_TFM'] = '1'
-
if env['fast']:
cpppath = []
if env.has_key ('CPPPATH'):
'Development files for pango, with FreeType2',
'pango1.0'):
conf.env['DEFINES']['HAVE_PANGO_FT2'] = '1'
- conf.env['DEFINES']['HAVE_PANGO16'] = '1'
if test_lib (optional, 'fontconfig', '2.2.0',
'Development files for fontconfig', 'fontconfig1'):
if env['gui']:
test_lib (required, 'gtk+-2.0', '2.4.0',
'Development files for GTK+', 'gtk2.0')
- if test_lib (required, 'pango', '1.6.0',
- 'Development files for pango', 'pango1.0'):
- conf.env['DEFINES']['HAVE_PANGO16'] = '1'
- if conf.CheckCHeader ('pango/pangofc-fontmap.h'):
- conf.env['DEFINES']['HAVE_PANGO_PANGOFC_FONTMAP_H'] = '1'
if env['fast']:
# Using CCFLAGS = -I<system-dir> rather than CPPPATH = [
# <system-dir>] speeds up SCons
LILYPONDPREFIX = os.path.join (run_prefix, 'share/lilypond/', version)
env.Append (ENV = {
- #'LILYPONDPREFIX' : os.path.join (run_prefix, 'share/lilypond/', version),
'LILYPONDPREFIX' : LILYPONDPREFIX,
- # ugh, can't use LILYPONDPREFIX here
- #'TEXMF' : '{' + os.path.join (run_prefix, 'share/lilypond/', version)\
- #+ ',' \
'TEXMF' : '{$LILYPONDPREFIX,'
+ os.popen ('kpsexpand \$TEXMF').read ()[:-1] + '}',
})
env.Append (CCFLAGS = ['-g'])
if env['optimising']:
env.Append (CCFLAGS = '-O2')
- env.Append (CXXFLAGS = ['-DSTRING_UTILS_INLINED'])
if env['warnings']:
env.Append (CCFLAGS = ['-W', '-Wall'])
env.Append (CXXFLAGS = ['-Wconversion'])
# Declare SConscript phonies
env.Alias ('minimal', config_cache)
-env.Alias ('mf-essential', config_cache)
-env.Alias ('minimal', ['lily', 'mf-essential'])
-env.Alias ('all', ['minimal', 'mf', '.'])
+if 0:
+ env.Alias ('mf-essential', config_cache)
+ env.Alias ('minimal', ['python', 'lily', 'mf-essential'])
+ env.Alias ('all', ['minimal', 'mf', '.'])
+
+else:
+ env.Alias ('minimal', ['python', 'mf', 'lily'])
+ env.Alias ('all', ['minimal', '.'])
+
+
# Do we want the doc/web separation?
env.Alias ('doc',
- ['Documentation',
+ ['minimal',
+ 'Documentation',
'Documentation/user',
'Documentation/topdocs',
'Documentation/bibliography',
LILYPONDPREFIX = LILYPONDPREFIX,
# FIXME: move to lily/SConscript?
- LIBPATH = [os.path.join (absbuild, 'flower', env['out']),
- os.path.join (absbuild, 'kpath-guile', env['out']),],
+ LIBPATH = [os.path.join (absbuild, 'flower', env['out'])],
CPPPATH = [outdir, ],
LILYPOND_PATH = ['.',
'$srcdir/input',
% vars ())
os.chdir (srcdir)
-if 1: #env['debugging']:
- stamp = os.path.join (run_prefix, 'stamp')
- env.Command (stamp, ['#/SConstruct', '#/VERSION'],
- [symlink_tree, 'touch $TARGET'])
- env.Depends ('lily', stamp)
-
+env.Command (LILYPONDPREFIX, ['#/SConstruct', '#/VERSION'], symlink_tree)
+env.Depends ('lily', LILYPONDPREFIX)
+env.Depends ('doc', LILYPONDPREFIX)
+
#### dist, tar
def plus (a, b):
a + b
and 'web' not in COMMAND_LINE_TARGETS\
and 'install' not in COMMAND_LINE_TARGETS\
and 'clean' not in COMMAND_LINE_TARGETS:
- subdirs = ['lily',
+ subdirs = [ 'python',
+ 'lily',
'flower',
- 'kpath-guile',
'mf',
- 'python',
]
if os.path.isdir ('%(srcdir)s/CVS' % vars ()):
# Setup LilyPond environment. For the LilyPond build, we override
# some of these commands in the ENVironment.
+lilypond_book_flags = '''--format=$LILYPOND_BOOK_FORMAT --process="lilypond -I$srcdir -I$srcdir/input/test $__verbose --backend=eps --formats=ps,png --header=texidoc -dinternal-type-checking -ddump-signatures -danti-alias-factor=2 -dgs-font-load" '''
+
env.Append (
- _fixme = _fixme,
- ##ABC2LY = 'abc2ly',
- ##LILYPOND = 'lilypond',
+ BSTINPUTS = '${SOURCE.dir}:${TARGET.dir}:',
+ BIB2HTML = '$PYTHON $srcdir/buildscripts/bib2html.py',
LILYOND_BOOK = 'lilypond-book',
-
- #ugr
- #LILYPOND_BOOK_FORMAT = 'texi',
LILYPOND_BOOK_FORMAT = '',
- #LILYPOND_BOOK_FLAGS = ['--format=$LILYPOND_BOOK_FORMAT'],
- LILYPOND_BOOK_FLAGS = '''--format=$LILYPOND_BOOK_FORMAT --process="lilypond --backend=eps --formats=ps,png --header=texidoc -I$srcdir/input/test -e '(ly:set-option (quote internal-type-checking) #t)'" ''',
-
+ LILYPOND_BOOK_FLAGS = lilypond_book_flags,
LILYPOND_PATH = [],
# The SCons way around FOO_PATH:
- ##LILYPOND_INCFLAGS = '$( ${_concat(INCPREFIX, LILYPOND_PATH, INCSUFFIX, __env__, RDirs)} $)',
LILYPOND_INCFLAGS = '$( ${_concat(INCPREFIX, LILYPOND_PATH, INCSUFFIX, __env__)} $)',
MAKEINFO_PATH = [],
MAKEINFO_FLAGS = [],
MAKEINFO_INCFLAGS = '$( ${_concat(INCPREFIX, MAKEINFO_PATH, INCSUFFIX, __env__, RDirs)} $)',
- # should not be necessary
- # PYTHONPATH = ['$absbuild/python/$out'],
- TEXI2DVI_FLAGS = [],
+ #TEXI2DVI_FLAGS = [],
_TEXI2DVI_FLAGS = '$( ${_concat(" ", TEXI2DVI_FLAGS,)} $)',
)
TEXIDVI =\
Builder (action = 'cd ${TARGET.dir} && \
- texi2dvi --batch $_TEXI2DVI_FLAGS ${SOURCE.file}',
+ texi2dvi --batch -I $srcdir/Documentation/user $_TEXI2DVI_FLAGS ${SOURCE.file}',
suffix = '.dvi', src_suffix = '.texi')
env.Append (BUILDERS = {'TEXIDVI': TEXIDVI})
suffix = '.eps', src_suffix = '.png')
env.Append (BUILDERS = {'PNG2EPS': PNG2EPS})
-
-
-# FIXME: cleanup, see above
-
-
-env.Append (
-
- #urg
- BSTINPUTS = '${SOURCE.dir}:${TARGET.dir}:',
- BIB2HTML = '$PYTHON $srcdir/buildscripts/bib2html.py',
-)
-
+EPS2PNG =\
+ Builder (action = 'convert $SOURCE $TARGET',
+ suffix = '.png', src_suffix = '.eps')
+env.Append (BUILDERS = {'EPS2PNG': EPS2PNG})
def add_ps_target (target, source, env):
base = os.path.splitext (str (target[0]))[0]
def add_enc_src (target, source, env):
base = os.path.splitext (str (target[0]))[0]
- return (target, source + [base + '.enc'])
+ #return (target, source + [base + '.enc'])
+ return (target + [base + '.pfb', base + '.svg'], source + [base + '.enc'])
+
+def add_svg (target, source, env):
+ base = os.path.splitext (str (target[0]))[0]
+ return (target + [base + '.svg'], source)
# FIXME UGH, should fix --output option for mftrace
a = 'cd ${TARGET.dir} && \
if test -e ${SOURCE.filebase}.enc; then encoding="--encoding=${SOURCE.filebase}.enc"; fi; \
MFINPUTS=$srcdir/mf:.: \
-$MFTRACE --formats=pfa --simplify --keep-trying --no-afm \
+$MFTRACE --formats=pfa,pfb,svg --simplify --keep-trying --no-afm \
$$encoding $__verbose \
--include=${TARGET.dir} \
${SOURCE.file}'
suffix = '.otf',
src_suffix = '.pe',
# emitter = add_cff_cffps_svg
+ emitter = add_svg
)
env.Append (BUILDERS = {'OTF': otf})
'step-bindir',
]
-# naming
def at_copy (target, source, env):
n = str (source[0])
s = open (n).read ()
AT_COPY = Builder (action = at_copy, src_suffix = ['.in', '.py', '.sh',])
env.Append (BUILDERS = {'AT_COPY': AT_COPY})
-# naming
def at_copy_ext (target, source, env):
n = str (source[0])
s = open (n).read ()
suffix = '.mo', src_suffix = '.po')
env.Append (BUILDERS = {'MO': MO})
-# ' '; ?
ugh = 'ln -f po/lilypond.pot ${TARGET.dir}/lilypond.po ; '
a = ugh + 'xgettext --default-domain=lilypond --join \
--output-dir=${TARGET.dir} --add-comments \
POMERGE = Builder (action = a, suffix = '.pom', src_suffix = '.po')
env.Append (BUILDERS = {'POMERGE': POMERGE})
-#UGRr
a = 'BSTINPUTS=$BSTINPUTS $BIB2HTML -o $TARGET $SOURCE'
BIB2HTML = Builder (action = a, suffix = '.html', src_suffix = '.bib')
env.Append (BUILDERS = {'BIB2HTML': BIB2HTML})
env.Append (BUILDERS = {'LYS2TELY': LYS2TELY})
-def mutopia (ly = None, abc = None):
-
- # FIXME: ugr, huh? The values from ../SConstruct get appended
- # to the predefined values from this builder context:
-
- # abc2ly/usr/bin/python ..../abc2.py
-
- # Override them again to fix web build...
-
-
- #BUILD_ABC2LY = '${set__x}$PYTHON $srcdir/scripts/abc2ly.py'
- #BUILD_LILYPOND = '$absbuild/$out/lilypond ${__verbose}'
+def mutopia (ly=None, abc=None):
e = env.Copy (
- #LILYPOND = BUILD_LILYPOND,
- #ABC2LY = BUILD_ABC2LY,
- )
+ LILYPOND_BOOK_FLAGS = lilypond_book_flags,
+ )
if not abc:
abc = base_glob ('*.abc')
if not ly:
ly = base_glob ('*.ly') + map (e.ABC, abc)
pdf = map (e.LilyPond, ly)
-
- # We need lily and mf to build these.
env.Depends (pdf, ['#/lily', '#/mf'])
env.Alias ('doc', pdf)
Export ('mutopia')
-
def collate (title = 'collated files'):
ly = base_glob ('*.ly')
e = env.Copy (
TITLE = title,
- LILYPOND_BOOK_FLAGS = '''--process="lilypond --backend=eps --formats=ps,png --header=texidoc -I$srcdir/input/test -e '(ly:set-option (quote internal-type-checking) #t)'" ''',
- __verbose = ' --verbose',
- )
- #
+ LILYPOND_BOOK_FLAGS = lilypond_book_flags,
+ # __verbose = ' --verbose',
+ )
tely = e.LYS2TELY ('collated-files', ly)
texi = e.TEXI (tely)
- # We need lily and mf to build these.
env.Depends (texi, ['#/lily', '#/mf'])
dvi = e.TEXIDVI (texi)
pspdf = e.DVIPDF (dvi)
CPPPATH = [
'#/lily/include',
'#/flower/include',
- '#/kpath-guile/include',
outdir],
LEXFLAGS = ['-Cfe', '-p', '-p'],
LIBS = ['flower'],
font_config_global = FcInitLoadConfig ();
FcChar8 *cache_file = FcConfigGetCache (font_config_global);
+ if (!cache_file)
+ {
+ programming_error ("global fontconfig cache_file not found");
+ return;
+ }
+
/*
This is a terrible kludge, but there is apparently no way for
FontConfig to signal whether it needs to rescan directories.
*/
if (!is_file ((char*)cache_file))
- message (_f ("Rebuilding FontConfig cache %s. this may take a while...", cache_file));
+ message (_f ("Rebuilding FontConfig cache %s, this may take a while...", cache_file));
vector<string> dirs;
import string
Import ('env', 'base_glob', 'install')
-xfeta = reduce (lambda x, y: x + y,
+feta = reduce (lambda x, y: x + y,
map (lambda x: base_glob (x),
('feta[0-9]*.mf',
'feta-alphabet*[0-9].mf',
feta_braces = base_glob ('feta-braces-[a-z].mf')
parmesan = base_glob ('parmesan[0-9][0-9]*.mf')
-# .pfa rules want an encoding file; ecb10.enc
-#sauter = ['ecb10']
-sauter = []
-fonts = feta + feta_alphabet + feta_braces + parmesan + sauter
-#env['feta'] = string.join (feta)
-#env['sauter'] = ''
+fonts = feta + feta_alphabet + feta_braces + parmesan
feta_sizes = map (lambda x: re.sub ('feta([0-9]+)', '\\1', x), feta)
otfs = map (lambda x: 'emmentaler-' + x, feta_sizes) + ['aybabtu']
t = map (env.TFM, fonts)
g = map (env.GTABLE, fonts)
-# FIXME: don't know how to add prefix: PFAEmmentaler (naming is ugly anyway)
-#p = map (env.PFA, fonts + map (lambda x: 'PFA' + x, otfs))
p = map (env.PFA, fonts)
-#e = map (env.ENC, fonts)
-#c = map (lambda x: x + '.cff', fonts)
-cp = map (lambda x: x + '.cff.ps', fonts)
e = map (lambda x: x + '.enc', fonts)
s = map (lambda x: x + '.svg', fonts)
o = map (env.OTF, otfs)
f = map (env.OTF_TABLE, feta)
g = map (env.OTF_TABLE, feta_braces)
+map (lambda x: env.Depends ('feta' + x + '.otf-table',
+ ['parmesan' + x + '.lisp',
+ 'feta-alphabet' + x + '.lisp']), feta_sizes)
+
map (lambda x: env.Depends ('emmentaler-' + x + '.otf',
'feta' + x + '.otf-table'),
feta_sizes)
-env.Command ('emmentaler-11.pe',
- '$srcdir/buildscripts/gen-emmentaler-scripts.py',
- '$PYTHON $srcdir/buildscripts/gen-emmentaler-scripts.py --dir=${TARGET.dir}')
-
-env.Command ('emmentaler-13.pe',
- '$srcdir/buildscripts/gen-emmentaler-scripts.py',
- '$PYTHON $srcdir/buildscripts/gen-emmentaler-scripts.py --dir=${TARGET.dir}')
-
-env.Command ('emmentaler-14.pe',
- '$srcdir/buildscripts/gen-emmentaler-scripts.py',
- '$PYTHON $srcdir/buildscripts/gen-emmentaler-scripts.py --dir=${TARGET.dir}')
-
-env.Command ('emmentaler-16.pe',
- '$srcdir/buildscripts/gen-emmentaler-scripts.py',
- '$PYTHON $srcdir/buildscripts/gen-emmentaler-scripts.py --dir=${TARGET.dir}')
-
-env.Command ('emmentaler-18.pe',
- '$srcdir/buildscripts/gen-emmentaler-scripts.py',
- '$PYTHON $srcdir/buildscripts/gen-emmentaler-scripts.py --dir=${TARGET.dir}')
-
-env.Command ('emmentaler-20.pe',
- '$srcdir/buildscripts/gen-emmentaler-scripts.py',
- '$PYTHON $srcdir/buildscripts/gen-emmentaler-scripts.py --dir=${TARGET.dir}')
-
-env.Command ('emmentaler-23.pe',
- '$srcdir/buildscripts/gen-emmentaler-scripts.py',
- '$PYTHON $srcdir/buildscripts/gen-emmentaler-scripts.py --dir=${TARGET.dir}')
+map (lambda x: env.Depends ('emmentaler-' + x + '.otf',
+ ['feta' + x + '.pfa',
+ 'parmesan' + x + '.pfa',
+ 'feta-alphabet' + x + '.pfa']), feta_sizes)
-env.Command ('emmentaler-26.pe',
- '$srcdir/buildscripts/gen-emmentaler-scripts.py',
- '$PYTHON $srcdir/buildscripts/gen-emmentaler-scripts.py --dir=${TARGET.dir}')
+for i in feta_sizes:
+ env.Command ('emmentaler-%(i)s.pe' % locals (),
+ '$srcdir/buildscripts/gen-emmentaler-scripts.py',
+ '$PYTHON $srcdir/buildscripts/gen-emmentaler-scripts.py --dir=${TARGET.dir}')
map (lambda x: env.Depends (x + '.pfa', x + '.enc'), feta)
# Aybabtu
-# ugh
-##feta_braces = map (lambda x: 'feta-braces-%c' % (ord ('a') + x), range (9))
+feta_braces_pfa = map (lambda x: x + '.pfa', feta_braces)
env.AT_COPY ('aybabtu.pe.in')
env.Command ('aybabtu.fontname', '', 'echo -n aybabtu > $TARGET')
map (lambda x: x + '.otf-gtable', feta_braces),
'echo "(design_size . 20)" > $TARGET')
-#env.Depends ('aybabtu.otf-table',
-# map (lambda x: x + '.otf-table', feta_braces))
-
-env.Depends ('aybabtu.otf', 'aybabtu.subfonts')
-env.Depends ('aybabtu.otf', 'aybabtu.fontname')
-env.Depends ('aybabtu.otf', 'aybabtu.otf-table')
-env.Depends ('aybabtu.otf', 'aybabtu.otf-gtable')
-
-# Hmm?
-#env.Depends ('aybabtu.pfa', 'aybabtu.subfonts')
-#env.Depends ('aybabtu.pfa', 'aybabtu.fontname')
-#env.Depends ('aybabtu.pfa', 'aybabtu.otf-table')
-#env.Depends ('aybabtu.pfa', 'aybabtu.otf-gtable')
-
-
-## FIXME
+env.Depends ('aybabtu.otf',
+ feta_braces_pfa
+ + ['aybabtu.subfonts',
+ 'aybabtu.fontname',
+ 'aybabtu.otf-table',
+ 'aybabtu.otf-gtable'])
+
+env.Command ('fonts.cache-1', p + o,
+ 'cd ${TARGET.dir}; fc-cache .')
+
+## FIXME: building only a few fonts does not seem to work anymore.
+## what is essential these days, aybabtu/emmentaler are needed always?
mf_essential = ['feta16', 'feta20', 'parmesan16', ]
-pfa_essential = map (env.PFA, mf_essential)
+pfa_essential = map (env.PFA, mf_essential) + ['emmentaler-20.otf']
env.Alias ('mf-essential', pfa_essential)
+env.Alias ('mf-essential', 'fonts.cache-1')
env['fonts'] = string.join (fonts)
env['feta_sizes'] = string.join (feta_sizes)
-env['sauter'] = string.join (sauter)
-env.Command ('lilypond.map', p,
- ['for i in $fonts; do echo $$i $$i "<"$$i.pfa; done > $TARGET',
- 'for i in $feta_sizes; do\
- echo "Emmentaler-$$i Emmentaler-$$i <emmentaler-$$i.cff.ps";\
- echo "PFAEmmentaler-$$i PFAEmmentaler-$$i <PFAemmentaler-$$i.pfa";\
- done >> $TARGET',
- 'echo "Aybabtu-Regular Aybabtu-Regular <aybabtu.cff.ps" >> $TARGET',
- 'echo "PFAAybabtu-Regular PFAAybabtu-Regular <aybabtu.cff.ps" >> $TARGET',
- 'for i in $sauter; do echo "$$i $$i <$$i.pfa"; done >> $TARGET'])
-#env.Alias ('mf', 'lilypond.map')
-
-env.Command ('fonts.scale', p,
- 'cd ${TARGET.dir} && echo *.pfa *.pfb | $PYTHON $srcdir/buildscripts/make-font-dir.py > $TARGET.file')
-env.Alias ('mf', 'fonts.scale')
-
-env.Command ('Fontmap', p,
- ["echo '%!' > $TARGET",
- "echo '% Override default GS Fontmap' >> $TARGET",
- "echo '% To let gs load fonts from builddir, do:' >> $TARGET",
- "echo '% export GS_LIB=$$(pwd)/mf/out:' >> $TARGET",
- "echo '% See Fontmap.GS for the syntax of real Fontmap files.' >> $TARGET",
- "echo '(Fontmap.GS) .runlibfile' >> $TARGET",
- "echo '(Fontmap.lily) .runlibfile' >> $TARGET"])
-
-env.Command ('Fontmap.lily', p + ['Fontmap'],
- ['echo "%!" > $TARGET',
- '''for i in $fonts; do echo "/$$i ($$i.pfa);"; done >> $TARGET''',
- ''' for i in $feta_sizes; do \
- echo "/Emmentaler-$$i (emmentaler-$$i.cff.ps);" ; \
- echo "/PFAEmmentaler-$$i (PFAemmentaler-$$i.pfa);" ; \
- done >> $TARGET''',
- '''echo "/Aybabtu (aybabtu.cff.ps);" >> $TARGET''',
- '''echo "/PFAAybabtu (PFAaybabtu.pfa);" >> $TARGET''',
- '''for i in $sauter; do echo "$$i ($$i.pfa);"; done >> $TARGET'''])
-#env.Alias ('mf', 'Fontmap.lily')
-
-# build essential stuff first, that's friendlier
+
env.Alias ('mf', pfa_essential + p + map (lambda x: x[0], o))
+env.Alias ('mf', s)
+env.Alias ('mf', 'fonts.cache-1')
install (t, env['sharedir_package_version'] + '/fonts/tfm')
install (p, env['sharedir_package_version'] + '/fonts/type1')
install (o, env['sharedir_package_version'] + '/fonts/otf')
install (e, env['sharedir_package_version'] + '/ps')
install (s, env['sharedir_package_version'] + '/fonts/svg')
-#install (c, env['sharedir_package_version'] + '/fonts/cff')
-install (cp, env['sharedir_package_version'] + '/ps')
(pitch ,ly:pitch? "the pitch of this note")
(pitch-alist ,list? "list of pitches jointly forming the scale of a key signature")
(pop-first ,boolean? "Do a revert before we try to do a override on some grob property.")
+ (prob-property ,symbol? "The symbol of the prob property to set. ")
(procedure ,procedure?
"The function to run with \\applycontext.
It must take a single argument, being the context.")
ly:output-def-scope
ly:output-description
ly:paper-book?
+ ly:prob-property
ly:layout-def?
ly:paper-get-font
ly:paper-get-number
def my_system (cmd):
status = ly.system (cmd,
be_verbose=global_options.verbose,
- progress_p= 1)
+ progress_p=1)
if global_options.format in (HTML, TEXINFO):
- cmd += ' --format png '
+ cmd += ' --formats=png '
# UGH
# the --process=CMD switch is a bad idea