push2: port registration, LED setup
[ardour.git] / libs / surfaces / push2 / wscript
1 #!/usr/bin/env python
2 from waflib.extras import autowaf as autowaf
3 import os
4
5 # Mandatory variables
6 top = '.'
7 out = 'build'
8
9 print "this is push2"
10
11 def options(opt):
12     autowaf.set_options(opt)
13     
14 def configure(conf):
15     conf.load ('compiler_cxx')
16     autowaf.configure(conf)
17     autowaf.check_pkg(conf, 'pangomm-1.4', uselib_store='PANGOMM', atleast_version='1.4', mandatory=True)
18     autowaf.check_pkg(conf, 'cairomm-1.0', uselib_store='CAIROMM', atleast_version='1.8.4', mandatory=True)
19
20 def build(bld):
21     obj = bld(features = 'cxx cxxshlib')
22     obj.source = '''
23             push2.cc
24             interface.cc
25             midi_byte_array.cc
26             leds.cc
27     '''
28     obj.export_includes = ['.']
29     obj.defines      = [ 'PACKAGE="ardour_push2"' ]
30     obj.defines     += [ 'ARDOURSURFACE_DLL_EXPORTS' ]
31     obj.includes     = [ '.', './push2']
32     obj.name         = 'libardour_push2'
33     obj.target       = 'ardour_push2'
34     obj.uselib       = 'CAIROMM PANGOMM USB'
35     obj.use          = 'libardour libardour_cp libpbd'
36     obj.install_path = os.path.join(bld.env['LIBDIR'], 'surfaces')
37
38 def shutdown():
39     autowaf.shutdown()