src/test/wscript
author Gustavo J. A. M. Carneiro <gjc@inescporto.pt>
Thu, 08 Sep 2011 16:13:40 +0100
changeset 7487 82cd20da9650
parent 7300 fbeb6b1cca20
child 7683 f3a3a218e6ab
permissions -rw-r--r--
Upgrade to waf-1.6.7, work in progress

## -*- Mode: python; py-indent-offset: 4; indent-tabs-mode: nil; coding: utf-8; -*-

import sys

def configure(conf):
    conf.sub_config('perf')
    conf.sub_config('ns3tcp')
    conf.sub_config('ns3wifi')

    # Add the test module to the list of enabled modules that should
    # not be built if this is a static build on Darwin.  They don't
    # work there for the test module, and this is probably because the
    # test module has no source files.
    if conf.env['ENABLE_STATIC_NS3'] and sys.platform == 'darwin':
        conf.env['MODULES_NOT_BUILT'].append('test')

def build(bld):
    # Don't do anything for this module if it should not be built.
    if 'test' in bld.env['MODULES_NOT_BUILT']:
        return

    test = bld.create_ns3_module('test', ['internet', 'mobility', 'applications', 'csma', 'bridge', 'config-store', 'tools', 'point-to-point', 'csma-layout', 'flow-monitor'])
    headers = bld.new_task_gen(features=['ns3header'])
    headers.module = 'test'

    test_test = bld.create_ns3_module_test_library('test')
    test_test.source = [
        'csma-system-test-suite.cc',
        'global-routing-test-suite.cc',
        'static-routing-test-suite.cc',
        'error-model-test-suite.cc',
        'mobility-test-suite.cc',
        ]