blob: 700e955602beb1ebf1ae58f49771e1344be0ab58 [file] [log] [blame]
Alexander Afanasyev7a696fb2012-03-01 17:17:22 -08001# -*- Mode: python; py-indent-offset: 4; indent-tabs-mode: nil; coding: utf-8; -*-
2
Alexander Afanasyeve76f2632012-03-05 00:18:42 -08003def options(opt):
4 opt.load('compiler_c')
5 opt.load('compiler_cxx')
6 opt.tool_options('boost', tooldir=["waf-tools"])
Alexander Afanasyev7a696fb2012-03-01 17:17:22 -08007
Alexander Afanasyev8f25cbb2012-03-01 23:53:40 -08008def configure(conf):
Alexander Afanasyeve76f2632012-03-05 00:18:42 -08009 conf.load("compiler_cxx")
Alexander Afanasyev8f25cbb2012-03-01 23:53:40 -080010 conf.check_cfg(atleast_pkgconfig_version='0.20')
11 conf.check_cfg(package='openssl', args=['--cflags', '--libs'], uselib_store='SSL')
Alexander Afanasyev146a51b2012-03-05 10:47:35 -080012 conf.define ('STANDALONE', 1)
Alexander Afanasyev7a696fb2012-03-01 17:17:22 -080013
Alexander Afanasyeve76f2632012-03-05 00:18:42 -080014 conf.check_tool('boost')
15 conf.check_boost(lib='signals filesystem iostreams regex')
16 if not conf.env.LIB_BOOST:
17 conf.check_boost(lib='signals filesystem iostreams regex', libpath="/usr/lib64")
18
Alexander Afanasyev7a696fb2012-03-01 17:17:22 -080019def build (bld):
Alexander Afanasyev146a51b2012-03-05 10:47:35 -080020 module = bld.new_task_gen(target="sync", features=['cxx', 'cxxshlib'])
Alexander Afanasyeve76f2632012-03-05 00:18:42 -080021 module.source = bld.path.ant_glob(['model/*.cc',
22 'helper/*.cc'])
23 module.uselib = 'BOOST BOOST_IOSTREAMS SSL'
24
Alexander Afanasyev146a51b2012-03-05 10:47:35 -080025# def build_ns3 (bld):
26# deps = ['core', 'network', 'NDNabstraction']
27# if bld.env['ENABLE_PYTHON_BINDINGS']:
28# deps.append ('visualizer')
Alexander Afanasyev7a696fb2012-03-01 17:17:22 -080029
Alexander Afanasyev146a51b2012-03-05 10:47:35 -080030# module = bld.create_ns3_module ('sync', deps)
31# module.uselib = 'BOOST BOOST_IOSTREAMS SSL'
Alexander Afanasyev7a696fb2012-03-01 17:17:22 -080032
Alexander Afanasyev146a51b2012-03-05 10:47:35 -080033# # tests = bld.create_ns3_module_test_library('sync')
34# # tests.source = [
35# # 'test/sync-test-suite.cc',
36# # ]
Alexander Afanasyev7a696fb2012-03-01 17:17:22 -080037
Alexander Afanasyev146a51b2012-03-05 10:47:35 -080038# headers = bld.new_task_gen(features=['ns3header'])
39# headers.module = 'sync'
40# headers.source = [
41# 'model/sync-app.h',
42# ]
Alexander Afanasyev7a696fb2012-03-01 17:17:22 -080043
Alexander Afanasyev146a51b2012-03-05 10:47:35 -080044# # if not bld.env['ENABLE_NDN_ABSTRACT']:
45# # bld.env['MODULES_NOT_BUILT'].append('NDNabstraction')
46# # return
Alexander Afanasyev7a696fb2012-03-01 17:17:22 -080047
Alexander Afanasyev146a51b2012-03-05 10:47:35 -080048# module.source = bld.path.ant_glob(['model/*.cc',
49# 'helper/*.cc'])
Alexander Afanasyev7a696fb2012-03-01 17:17:22 -080050
Alexander Afanasyev146a51b2012-03-05 10:47:35 -080051# # if bld.env.ENABLE_EXAMPLES:
52# # bld.add_subdirs('examples')
Alexander Afanasyev7a696fb2012-03-01 17:17:22 -080053
Alexander Afanasyev146a51b2012-03-05 10:47:35 -080054# # bld.ns3_python_bindings()
Alexander Afanasyev7a696fb2012-03-01 17:17:22 -080055