# -*-python-*-

Import ('env', 'src_glob', 'install')

outdir = Dir ('.').abspath

cc_sources =  src_glob ('*.cc')
sources = cc_sources + ['parser.yy', 'lexer.ll']
includes = src_glob ('include/*.hh')

e = env.Copy ()

e.Append (
	CPPPATH = [
	  '#/lily/include',
	  '#/flower/include',
	  outdir],
	LEXFLAGS = ['-Cfe', '-p', '-p'],
	LIBS = ['flower'],
	)

e.HH ('parser.hh', 'parser.yy')
e.ParseConfig ('guile-config link')
lily = e.Program ('lilypond', sources)
install (lily, env['bindir'])

# let's not, for now
#po = env.Command ('lilypond.po', cc_sources + includes, env['pocommand'])
#env.Alias ('po-update', po)
