~ubuntu-branches/ubuntu/trusty/gnome-python/trusty

« back to all changes in this revision

Viewing changes to gnomecanvas/wscript

  • Committer: Bazaar Package Importer
  • Author(s): Sebastien Bacher
  • Date: 2008-06-16 15:56:14 UTC
  • mto: (3.2.1 sid) (62.1.1 sid)
  • mto: This revision was merged to the branch mainline in revision 43.
  • Revision ID: james.westby@ubuntu.com-20080616155614-k8ib2wq7jay8zaaz
Tags: upstream-2.22.1
ImportĀ upstreamĀ versionĀ 2.22.1

Show diffs side-by-side

added added

removed removed

Lines of Context:
5
5
import Common
6
6
 
7
7
def configure(conf):
8
 
    conf.env['ENABLE_CANVAS'] = bool(conf.check_pkg(
9
 
            'libgnomecanvas-2.0 >= 2.8.0 pygobject-2.0 ',
10
 
            destvar='GNOMECANVAS', mandatory=False))
 
8
    conf.env.append_value('MODULES_AVAILABLE', 'gnomecanvas')
 
9
    
 
10
    if 'gnomecanvas' in conf.env['ENABLE_MODULES'] or 'all' in conf.env['ENABLE_MODULES']:
 
11
        if conf.check_pkg('libgnomecanvas-2.0 >= 2.8.0 pygobject-2.0 ',
 
12
                          destvar='GNOMECANVAS', mandatory=False):
 
13
            conf.env.append_value('MODULES_TO_BUILD', 'gnomecanvas')
 
14
 
11
15
 
12
16
def codegen(bld, module):
13
17
    cmd = bld.create_obj('command-output')
32
36
 
33
37
def build(bld):
34
38
    
35
 
    if bld.env()['ENABLE_CANVAS']:
 
39
    if 'gnomecanvas' in bld.env()['MODULES_TO_BUILD']:
36
40
        codegen(bld, 'canvas')
37
 
        pyext = bld.create_obj('cc', 'plugin', 'pyext')
 
41
        pyext = bld.create_pyext()
38
42
        pyext.source = 'canvasmodule.c canvas.c'
39
43
        pyext.target = 'gnomecanvas'
40
44
        pyext.uselib = 'GNOMECANVAS'
41
 
        #pyext.env.append_value('CPPPATH', '../canvas') # work around possible WAF bug
42
 
        pyext.install_var = 'PYTHONDIR'
43
 
        pyext.install_subdir = 'gtk-2.0'
 
45
        pyext.inst_var = 'PYTHONDIR'
 
46
        pyext.inst_dir = 'gtk-2.0'
44
47
 
45
48
        defsdir = Common.install_files('DATADIR', os.path.join('pygtk', '2.0', 'defs'),
46
49
                                       ['canvas.defs'])