File: wscript

package info (click to toggle)
xmms2 0.8%2Bdfsg-28
  • links: PTS, VCS
  • area: main
  • in suites: trixie
  • size: 14,216 kB
  • sloc: ansic: 63,803; python: 15,537; cpp: 5,718; xml: 1,479; perl: 338; ruby: 243; makefile: 79; sh: 59; asm: 7
file content (69 lines) | stat: -rw-r--r-- 2,373 bytes parent folder | download | duplicates (3)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
from waflib import Utils

def build(bld):
    t = bld(features = 'c cprogram',
        target = 'vistest',
        source = 'vistest.c',
        includes = '. ../../.. ../../include',
        uselib = 'glib2',
        use = 'xmmsclient-glib xmmsclient'
        )
    if not bld.env.INSTALL_VIS_REFERENCE_CLIENTS:
        t.install_path = None

    if bld.env.LIB_math:
        t = bld(features = 'c cprogram',
            target = 'vistest-fft',
            source = 'vistest_fft.c',
            includes = '. ../../.. ../../include',
            uselib = 'glib2 math',
            use = 'xmmsclient-glib xmmsclient'
            )
        if not bld.env.INSTALL_VIS_REFERENCE_CLIENTS:
            t.install_path = None


    if bld.env.LIB_vorbisenc:
        t = bld(features = 'c cprogram',
            target = 'xmms2-ripper',
            source = 'ripper.c',
            includes = '. ../../.. ../../include',
            uselib = 'vorbisenc',
            use = 'xmmsclient'
            )
        if not bld.env.INSTALL_VIS_REFERENCE_CLIENTS:
            t.install_path = None

    if bld.env.LIB_visual and bld.env.LIB_sdl:
        t = bld(features = 'c cprogram',
            target = 'xmms2-libvisual',
            source = 'libvisual.c',
            includes = '. ../../.. ../../include',
            uselib = 'sdl visual DISABLE_STRICTPROTOTYPES',
            use = 'xmmsclient'
            )
        if not bld.env.INSTALL_VIS_REFERENCE_CLIENTS:
            t.install_path = None

def configure(conf):
    if Utils.unversioned_sys_platform == "win32":
        conf.fatal("visualisation clients not supported on windows")

    conf.env.INSTALL_VIS_REFERENCE_CLIENTS = conf.options.with_vis_clients

    conf.check_cc(lib="m", uselib_store="math", mandatory=False)

    conf.check_cfg(package='vorbisenc', uselib_store='vorbisenc',
            args='--cflags --libs', mandatory=False)

    if conf.check_cfg(package='libvisual-0.4', uselib_store='visual',
            args='--cflags --libs', mandatory=False):
        conf.check_cfg(package='sdl', uselib_store='sdl',
                args='--cflags --libs', mandatory=False)


def options(opt):
    opt.add_option('--with-vis-reference-clients',
                   action='store_true', default=False,
                   dest='with_vis_clients',
                   help="Install the visualization reference clients")