diff -Naur ns-3.26/AUTHORS ns-3.27/AUTHORS --- ns-3.26/AUTHORS 2016-10-03 19:49:01.455389084 -0700 +++ ns-3.27/AUTHORS 2017-10-11 21:45:51.444599194 -0700 @@ -1,7 +1,10 @@ John Abraham (john.abraham.in@gmail.com) +Danilo Abrignani (dabrignani@gmail.com) Alexander Afanasyev (alexander.afanasyev@ucla.edu) Rohit Agarwal (mindprince@gmail.com) Piyush Aggarwal (piyush8311@gmail.com) +Zoraze Ali (zoraze.ali@cttc.es) +Robert Ammon (ammo6818@vandals.uidaho.edu) Kirill Andreev (andreev@iitp.ru) Dean Armstrong (deanarm@gmail.com) Stefano Avallone (stefano.avallone@unina.it) @@ -27,6 +30,7 @@ Tiago Cerqueira (tiago.miguel43@gmail.com) Egemen K. Cetinkaya (ekc@iitc.ku.edu) Angelos Chatzipapas (chatzipa@ceid.upatras.gr) +Luciano Jerez Chaves (ljerezchaves@gmail.com) Eugene Chemeritskiy (echemeritskiy@arccn.ru) Yufei Cheng (yfcheng@ittc.ku.edu) Andrey Churin (aachurin@gmail.com) @@ -38,6 +42,7 @@ Alexander D'souza (moijes12@gmail.com) Ankit Deepak (adadeepak8@gmail.com) Sébastien Deronne (sebastien.deronne@gmail.com) +Christoph Döpmann (doepmanc@informatik.hu-berlin.de) Craig Dowell (craigdo@ee.washington.edu) Gilaras Drakeson (gilaras@gmail.com) Christian Facchini (c.facchini@gmail.com) @@ -53,11 +58,13 @@ Thomas Geithner (thomas.geithner@dai-labor.de) Ashim Ghosh (ashim.atiit@gmail.com) Martin Giachino (martin.giachino@gmail.com,giachino@fing.edu.uy) +Nichit Bodhak Goel (nichit93@gmail.com) Tom Goff (tgoff@tgoff.net) Mohit Goyal (mohit.bits@gmail.com) Juan C. Granda (jcgranda@uniovi.es) David Gross (gdavid.devel@gmail.com) Maja Grubišić (maja.grubisic@live.com) +Federico Guerra (federico@guerra-tlc.com) Charline Taibi Guguen (charline.guguen@gmail.com) Daniel Halperin (daniel@halper.in) Bruno Haick (bghaick@hotmail.com) @@ -73,8 +80,10 @@ Pasquale Imputato (p.imputato@gmail.com) ishan (ishan.chhabra@gmail.com) Mohamed Amine Ismail (amine.ismail@inria.fr, iamine@udcast.com) +Toshio Ito (debug.ito@gmail.com) Jared Ivey (j.ivey@gatech.edu) Atishay Jain (atishayjain25@gmail.com) +Sourabh Jain (jainsourabh679@gmail.com) Sascha Alexander Jopen (jopen@informatik.uni-bonn.de) Sam Jansen (sam.jansen@gmail.com) Liu Jian (liujatp@gmail.com) @@ -83,6 +92,7 @@ Tanmay Kathpalia (tanmay.kathpalia@landisgyr.com) Konstantinos Katsaros (dinos.katsaros@gmail.com) Morteza Kheirkhah (m.kheirkhah@sussex.ac.uk) +Shravya Ks (shravya.ks0@gmail.com) Flavio Kubota (flaviokubota@gmail.com) Joe Kopena (tjkopena@cs.drexel.edu) Christopher Kosecki (christopher.l.kosecki.ctr@mail.mil) @@ -98,6 +108,7 @@ Timo Lindhorst (tlnd@online.de) Erwan Livolant (erwan.livolant@inria.fr) Andrea Lupia (alupia@dimes.unical.it) +Radu Lupu (rlupu@elcom.pub.ro) Keith Ma (keith.nwsuaf@gmail.com) Federico Maguolo (maguolof@dei.unipd.it) Antti Makela (zarhan@cc.hut.fi) @@ -107,6 +118,7 @@ Andrey Mazo (mazo@iitp.ru) Jonathan McCrohan (jmccroha@tcd.ie) Andrew McGregor (andrewmcgr@gmail.com) +Miralem Mehic (miralemmehic@gmail.com) Vedran Miletić (rivanvx@gmail.com) Saswat Mishra (clicksaswat@gmail.com) Jens Mittag (jens.mittag@kit.edu) @@ -129,6 +141,7 @@ Duy Nguyen (duy@soe.ucsc.edu) Luis Pacheco (luisbelem@gmail.com) Lluís Parcerisa (parcerisa@gmail.com) +Mingyu Park (darkpmg@naver.com) Natale Patriciello (natale.patriciello@gmail.com) Tommaso Pecorella (tommaso.pecorella@unifi.it) Guangyu Pei (guangyu.pei@boeing.com) @@ -139,17 +152,22 @@ Giuseppe Piro (g.piro@poliba.it) Randall Plate (rplate@spawar.navy.mil) Yana Podkosova (yanapdk@rambler.ru) +Michele Polese (michele.polese@gmail.com) Ovidiu Poncea (ovidiu.poncea@cs.pub.ro) Vikas Pushkar (vikaskupushkar@gmail.com) Andrea Ranieri (andreran@uno.it) Bruno Ranieri (Yrrsinn@googlemail.com) +Deepti Rajagopal (deeptir96@gmail.com) +Varun Reddy (varunamarreddy@gmail.com) Ken Renard (kenneth.renard@arl.army.mil) +Getachew Redieteab (redieteab.orange@gmail.com) Manuel Requena (mrequena@cttc.es) Matias Richart (mrichart@fing.edu.uy) George F. Riley (riley@ece.gatech.edu) Juergen Rinas (jrinas@gmx.de) Sebastian Rohde (sebastian.rohde@tu-dortmund.de) Karsten Roscher (sfx@rocktale.de) +Ali Rostami (a.rostami@rutgers.edu) Bill Roome (wdr@bell-labs.com) David (david.rua@gmail.com) Andrea Sacco (andrea.sacco85@gmail.com) @@ -157,6 +175,7 @@ Providence Salumu Munga (Providence.Salumu@gmail.com, Providence.Salumu_Munga@it-sudparis.eu) Francisco Javier Sánchez-Roselly (fnavarro@ujaen.es) Siddharth Santurkar (siddharth.santurkar@ieee.org) +Gaurav Sathe (gaurav.sathe@tcs.com) Robert R. Schmidt (rschmi@gmx.net) Florian Schmidt (Florian.Schmidt@cs.rwth-aachen.de) Guillaume Seguin (guillaume.seguin@inria.fr) @@ -169,12 +188,16 @@ Pedro Silva (pmms@inesctec.pt) Anirudh Sivaraman (sk.anirudh@gmail.com) Steven Smith (smith84@llnl.gov) +Izydor Sokoler (Izydor.sokoler@gmail.com) +Lauri Sormunen (lauri.sormunen@magister.fi) +Akin Soysal (akinsoysal@gmail.com) Andrew Stanton (acstanton515@gmail.com) Ewgenij Starostin (estar@cs.tu-berlin.de) YunQiang Su (wzssyqa@gmail.com) Brian Swenson (bswenson3@gatech.edu) Lalith Suresh (suresh.lalith@gmail.com) Mohit P. Tahiliani (tahiliani.nitk@gmail.com) +Rohit P. Tahiliani (tahiliar@tcd.ie) Dave Taht (dave.taht@bufferbloat.net) Marcos Talau (talau@users.sourceforge.net) Adrian S. W. Tam (adrian.sw.tam@gmail.com) @@ -193,6 +216,5 @@ Florian Westphal (fw@strlen.de) He Wu (mdzz@u.washington.edu) Yoshihiko Yazawa (yoshiyaz@gmail.com) +Menglei Zhang (menglei@nyu.edu) Dizhi Zhou (dizhi.zhou@gmail.com) -Gaurav Sathe (gaurav.sathe@tcs.com) -Ali Rostami (a.rostami@rutgers.edu) diff -Naur ns-3.26/bindings/python/ns3modulegen_core_customizations.py ns-3.27/bindings/python/ns3modulegen_core_customizations.py --- ns-3.26/bindings/python/ns3modulegen_core_customizations.py 2016-10-03 19:49:01.481388890 -0700 +++ ns-3.27/bindings/python/ns3modulegen_core_customizations.py 2017-10-11 21:45:51.478599305 -0700 @@ -71,7 +71,7 @@ args = tuple([correct_ctype] + list(args[1:])) handler = type_handler(*args, **kwargs) - handler.set_tranformation(self, orig_ctype) + handler.set_transformation(self, orig_ctype) return handler def untransform(self, type_handler, declarations, code_block, expression): diff -Naur ns-3.26/bindings/python/ns3modulescan-modular.py ns-3.27/bindings/python/ns3modulescan-modular.py --- ns-3.26/bindings/python/ns3modulescan-modular.py 2016-10-03 19:49:01.482388883 -0700 +++ ns-3.27/bindings/python/ns3modulescan-modular.py 2017-10-11 21:45:51.479599308 -0700 @@ -4,20 +4,21 @@ import os.path import pybindgen.settings -from pybindgen.gccxmlparser import ModuleParser, PygenClassifier, PygenSection, WrapperWarning, find_declaration_from_name +from pybindgen.castxmlparser import ModuleParser, PygenClassifier, PygenSection, WrapperWarning, find_declaration_from_name from pybindgen.typehandlers.codesink import FileCodeSink from pygccxml.declarations import templates from pygccxml.declarations.enumeration import enumeration_t from pygccxml.declarations.class_declaration import class_t -from pygccxml.declarations.calldef import free_function_t, member_function_t, constructor_t, calldef_t - +from pygccxml.declarations.free_calldef import free_function_t +from pygccxml.declarations.calldef_members import constructor_t, member_function_t +from pygccxml.declarations.calldef import calldef_t ## we need the smart pointer type transformation to be active even -## during gccxml scanning. +## during castxml scanning. import ns3modulegen_core_customizations -## silence gccxmlparser errors; we only want error handling in the +## silence castxmlparser errors; we only want error handling in the ## generated python script, not while scanning. class ErrorHandler(pybindgen.settings.ErrorHandler): def handle_error(self, dummy_wrapper, dummy_exception, dummy_traceback_): @@ -34,6 +35,8 @@ def get_ns3_relative_path(path): l = [] head = path + if not path: + return while head: new_head, tail = os.path.split(head) if new_head == head: @@ -58,7 +61,8 @@ ns3_header = get_ns3_relative_path(pygccxml_definition.location.file_name) except ValueError: # the header is not from ns3 return # ignore the definition, it's not ns-3 def. - + if not ns3_header: + return definition_module = self.headers_map[ns3_header] ## Note: we don't include line numbers in the comments because @@ -78,7 +82,7 @@ if isinstance(pygccxml_definition, member_function_t) \ and pygccxml_definition.parent.name == 'Object' \ and pygccxml_definition.name == 'GetObject': - template_args = templates.args(pygccxml_definition.demangled_name) + template_args = templates.args(str(pygccxml_definition)) if template_args == ['ns3::Object']: global_annotations['template_instance_names'] = 'ns3::Object=>GetObject' @@ -227,13 +231,13 @@ module_parser.add_pre_scan_hook(PreScanHook(headers_map, module_name)) #module_parser.add_post_scan_hook(post_scan_hook) - gccxml_options = dict( + castxml_options = dict( include_paths=[top_builddir], define_symbols={ #'NS3_ASSERT_ENABLE': None, #'NS3_LOG_ENABLE': None, }, - cflags=('--gccxml-cxxflags "%s -DPYTHON_SCAN"' % cflags) + cflags=('-std=c++14 %s' % cflags) ) try: @@ -255,9 +259,8 @@ module_parser.parse_init([scan_header], None, whitelist_paths=[top_builddir], - #includes=['"ns3/everything.h"'], pygen_sink=output_sink, - gccxml_options=gccxml_options) + castxml_options=castxml_options) module_parser.scan_types() callback_classes_file = open(os.path.join(os.path.dirname(output_file_name), "callbacks_list.py"), "wt") diff -Naur ns-3.26/bindings/python/ns3modulescan.py ns-3.27/bindings/python/ns3modulescan.py --- ns-3.26/bindings/python/ns3modulescan.py 2016-10-03 19:49:01.483388875 -0700 +++ ns-3.27/bindings/python/ns3modulescan.py 2017-10-11 21:45:51.480599311 -0700 @@ -8,7 +8,9 @@ from pybindgen.typehandlers.codesink import FileCodeSink from pygccxml.declarations import templates from pygccxml.declarations.class_declaration import class_t -from pygccxml.declarations.calldef import free_function_t, member_function_t, constructor_t, calldef_t +from pygccxml.declarations.free_calldef import free_function_t +from pygccxml.declarations.calldef_members import constructor_t, member_function_t +from pygccxml.declarations.calldef import calldef_t ## we need the smart pointer type transformation to be active even diff -Naur ns-3.26/bindings/python/wscript ns-3.27/bindings/python/wscript --- ns-3.26/bindings/python/wscript 2016-10-03 19:49:01.486388853 -0700 +++ ns-3.27/bindings/python/wscript 2017-10-11 21:45:51.799600345 -0700 @@ -14,8 +14,9 @@ # after = TaskGen.after # https://github.com/gjcarneiro/pybindgen -REQUIRED_PYBINDGEN_VERSION = '0.17.0.post57+nga6376f2' -REQUIRED_PYGCCXML_VERSION = (0, 9, 5) +REQUIRED_PYBINDGEN_VERSION = '0.17.0.post58+ngcf00cc0' +REQUIRED_PYGCCXML_VERSION = (1, 9, 0) +REQUIRED_CASTXML_VERSION = '0.1' RUN_ME=-3 @@ -51,7 +52,7 @@ dest='python_disable') opt.add_option('--apiscan', help=("Rescan the API for the indicated module(s), for Python bindings. " - "Needs working GCCXML / pygccxml environment. " + "Needs working CastXML / pygccxml environment. " "The metamodule 'all' expands to all available ns-3 modules."), default=None, dest='apiscan', metavar="MODULE[,MODULE...]") opt.add_option('--with-pybindgen', @@ -67,6 +68,17 @@ dest='no32bit_scan') +def split_version(version): + if (re.search ('post', version)): + # Version format such as '0.17.0.post58+ngcf00cc0' + ver = re.split('[.+]', version)[:4] + return (int(ver[0]), int(ver[1]), int(ver[2]), int(ver[3].split('post')[1])) + else: + # Version format such as '0.18.0' + ver = re.split('[.]', version)[:3] + return (int(ver[0]), int(ver[1]), int(ver[2]), 0) + + def configure(conf): conf.env['ENABLE_PYTHON_BINDINGS'] = False if Options.options.python_disable: @@ -183,7 +195,7 @@ stdout=subprocess.PIPE).communicate()[0] pybindgen_version = maybe_decode(out.strip()) conf.msg('Checking for pybindgen version', pybindgen_version) - if not (pybindgen_version == REQUIRED_PYBINDGEN_VERSION): + if not (split_version(pybindgen_version) >= split_version(REQUIRED_PYBINDGEN_VERSION)): Logs.warn("pybindgen (found %r), (need %r)" % (pybindgen_version, REQUIRED_PYBINDGEN_VERSION)) conf.report_optional_feature("python", "Python Bindings", False, @@ -257,7 +269,7 @@ try: conf.check_python_module('pygccxml') except Errors.ConfigurationError: - conf.report_optional_feature("pygccxml", "Python API Scanning Support", False, + conf.report_optional_feature("castxml", "Python API Scanning Support", False, "Missing 'pygccxml' Python module") return @@ -274,40 +286,43 @@ "automatic scanning of API definitions will not be possible" % (pygccxml_version_str, '.'.join([str(x) for x in REQUIRED_PYGCCXML_VERSION]))) - conf.report_optional_feature("pygccxml", "Python API Scanning Support", False, - "pygccxml too old") + conf.report_optional_feature("castxml", "Python API Scanning Support", False, + "pygccxml Python module too old") return - ## Check gccxml version + ## Check castxml version try: - gccxml = conf.find_program('gccxml', var='GCCXML') + castxml = conf.find_program('castxml', var='CASTXML') except WafError: - gccxml = None - if not gccxml: - Logs.warn("gccxml missing; automatic scanning of API definitions will not be possible") - conf.report_optional_feature("pygccxml", "Python API Scanning Support", False, - "gccxml missing") + castxml = None + if not castxml: + Logs.warn("castxml missing; automatic scanning of API definitions will not be possible") + conf.report_optional_feature("castxml", "Python API Scanning Support", False, + "castxml missing") return - gccxml_version_line = os.popen(gccxml[0] + " --version").readline().strip() - m = re.match( "^GCC-XML version (\d\.\d(\.\d)?)$", gccxml_version_line) + out = subprocess.Popen([castxml[0], '--version'], + stdout=subprocess.PIPE).communicate()[0] + castxml_version_line = maybe_decode(out).split('\n', 1)[0].strip() + ## Expecting version string such as 'castxml version 0.1-gfab9c47' + m = re.match( "^castxml version (\d\.\d)(-)?(\w+)?", castxml_version_line) try: - gccxml_version = m.group(1) - gccxml_version_ok = ([int(s) for s in gccxml_version.split('.')] >= [0, 9]) + castxml_version = m.group(1) + castxml_version_ok = castxml_version >= REQUIRED_CASTXML_VERSION except AttributeError: - gccxml_version = gccxml_version_line - gccxml_version_ok = False - conf.msg('Checking for gccxml version', gccxml_version) - if not gccxml_version_ok: - Logs.warn("gccxml version unknown or too old, need version >= 0.9; automatic scanning of API definitions will not be possible") - conf.report_optional_feature("pygccxml", "Python API Scanning Support", False, - "gccxml too old") + castxml_version = castxml_version_line + castxml_version_ok = False + conf.msg('Checking for castxml version', castxml_version) + if not castxml_version_ok: + Logs.warn("castxml version unknown or too old, need version >= %s; automatic scanning of API definitions will not be possible" % REQUIRED_CASTXML_VERSION) + conf.report_optional_feature("castxml", "Python API Scanning Support", False, + "castxml too old") return ## If we reached conf.env['ENABLE_PYTHON_SCANNING'] = True - conf.report_optional_feature("pygccxml", "Python API Scanning Support", True, None) + conf.report_optional_feature("castxml", "Python API Scanning Support", True, None) # --------------------- @@ -331,7 +346,7 @@ return ns3headers.path.abspath() class apiscan_task(Task.Task): - """Uses gccxml to scan the file 'everything.h' and extract API definitions. + """Uses castxml to scan the file 'everything.h' and extract API definitions. """ after = 'gen_ns3_module_header ns3header' before = 'cxx command' diff -Naur ns-3.26/CHANGES.html ns-3.27/CHANGES.html --- ns-3.26/CHANGES.html 2016-10-03 19:49:01.461389039 -0700 +++ ns-3.27/CHANGES.html 2017-10-11 21:45:51.452599220 -0700 @@ -51,6 +51,176 @@ us a note on ns-developers mailing list.


+

Changes from ns-3.26 to ns-3.27

+

New API:

+ +

Changes to existing API:

+ +

Changes to build system:

+ +

Changed behavior:

+ + +

Changes from ns-3.25 to ns-3.26

New API: