13
0
livetrax/libs/evoral/wscript
Hans Baier 446b214b46 * Evoral: first successful read from Sequence
*Evoral: added debug option to wscript


git-svn-id: svn://localhost/ardour2/branches/3.0@4497 d708f5d6-7413-0410-9779-e7cbd77b26cf
2009-02-07 06:57:02 +00:00

88 lines
2.1 KiB
Python

#!/usr/bin/env python
import autowaf
# Version of this package (even if built as a child)
EVORAL_VERSION = '0.0.0'
# Library version (UNIX style major, minor, micro)
# major increment <=> incompatible changes
# minor increment <=> compatible changes (additions)
# micro increment <=> no interface changes
# Version history:
# 0.0.0 = 0,0,0
EVORAL_LIB_VERSION = '0.0.0'
# Variables for 'waf dist'
APPNAME = 'evoral'
VERSION = EVORAL_VERSION
# Custom variables
DEBUG = True
if DEBUG:
cxxflags = '-g'
else:
cxxflags = ''
# Mandatory variables
srcdir = '.'
blddir = 'build'
def set_options(opt):
autowaf.set_options(opt)
def configure(conf):
autowaf.configure(conf)
autowaf.check_tool(conf, 'compiler_cxx')
autowaf.check_pkg(conf, 'glibmm-2.4', uselib_store='GLIBMM', atleast_version='2.14.0', mandatory=True)
autowaf.check_pkg(conf, 'gthread-2.0', uselib_store='GTHREAD', atleast_version='2.14.0', mandatory=True)
autowaf.check_pkg(conf, 'cppunit', uselib_store='CPPUNIT', atleast_version='1.12.0', mandatory=False)
def build(bld):
# Headers
#bld.install_files('${INCLUDEDIR}/evoral', 'evoral/*.h')
#bld.install_files('${INCLUDEDIR}/evoral', 'evoral/*.hpp')
# Pkgconfig file
#autowaf.build_pc(bld, 'EVORAL', EVORAL_VERSION, 'GLIBMM GTHREAD')
# Library
obj = bld.new_task_gen('cxx', 'shlib')
obj.source = '''
src/Control.cpp
src/ControlList.cpp
src/ControlSet.cpp
src/Curve.cpp
src/Event.cpp
src/MIDIEvent.cpp
src/Note.cpp
src/SMF.cpp
src/SMFReader.cpp
src/Sequence.cpp
'''
obj.export_incdirs = ['.']
obj.includes = ['.', './src']
obj.name = 'libevoral'
obj.target = 'evoral'
obj.uselib = 'GLIBMM GTHREAD'
obj.vnum = EVORAL_LIB_VERSION
obj.cxxflags = cxxflags
obj.install_path = ''
# Unit tests
obj = bld.new_task_gen('cxx', 'program')
obj.source = '''
test/sequence.cpp
test/testrunner.cpp
'''
obj.includes = ['.', './src']
obj.uselib_local = 'libevoral'
obj.uselib = 'CPPUNIT'
obj.target = 'run-tests'
obj.cxxflags = cxxflags
obj.install_path = ''
def shutdown():
autowaf.shutdown()