Bugzilla – Bug 1725
Netanim examples crash on cygwin
Last modified: 2013-07-23 13:40:00 EDT
VedranM@eddie-willers ~/ns-3-dev $ g++ --version g++ (GCC) 4.7.2 Copyright (C) 2012 Free Software Foundation, Inc. This is free software; see the source for copying conditions. There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. VedranM@eddie-willers ~/ns-3-dev $ uname -a CYGWIN_NT-6.1-WOW64 eddie-willers 1.7.20(0.266/5/3) 2013-06-07 11:11 i686 Cygwin VedranM@eddie-willers ~/ns-3-dev $ ./waf --run src/netanim/examples/dumbbell-animation Waf: Entering directory `/home/VedranM/ns-3-dev/build' Waf: Leaving directory `/home/VedranM/ns-3-dev/build' 'build' finished successfully (3.541s) assert failed. cond="uid != 0", msg="Assert in TypeId::LookupByName: ns3::WimaxN etDevice not found", file=../src/core/model/type-id.cc, line=419 terminate called without an active exception Command ['/home/VedranM/ns-3-dev/build/src/netanim/examples/ns3-dev-dumbbell-ani mation-debug'] terminated with signal SIGABRT. Run it under a debugger to get mo re information (./waf --run <program> --command-template="gdb --args %s <args>") .
does including "wimax-net-device.h" in animation-interface.cc resolve this? There is a runtime dependency on this due to the callbacks.
It is very similar to the problem discussed in https://groups.google.com/forum/#!topic/ns-3-users/j3eg1cFx8Qo I haven't got working cygwin setup with me , to test Tom's theory but to me it look waf related, as we already have wimax on the dependency list module = bld.create_ns3_module ('netanim', ['internet', 'mobility', 'wimax', 'wifi', 'csma', 'lte', 'uan'])
(In reply to comment #2) > It is very similar to the problem discussed in > https://groups.google.com/forum/#!topic/ns-3-users/j3eg1cFx8Qo > > I haven't got working cygwin setup with me , to test Tom's theory but to me it > look waf related, as we already have wimax on the dependency list > > module = bld.create_ns3_module ('netanim', ['internet', 'mobility', 'wimax', > 'wifi', 'csma', 'lte', 'uan']) I tested my idea on Cygwin earlier today-- didn't work. The problem is that the type id is not being registered for some reason. I can look at this some more over the next day or two. There are a few other Cygwin problems with ns-3.17, the fd-net-device wscript one that Vedran recently fixed, and matrix-topology.cc is not compiling for me.
John, any progress or more info on this?
Unfortunately, I am unable to even get past compilation issues [ 757/1696] cxx: utils/bench-simulator.cc -> build/utils/bench-simulator.cc.2.o ../utils/bench-simulator.cc: In member function `void Bench::RunBench()': ../utils/bench-simulator.cc:87: warning: passing `double' for converting 1 of `n s3::Time ns3::NanoSeconds(uint64_t)' ../utils/bench-simulator.cc: In member function `void Bench::Cb()': ../utils/bench-simulator.cc:121: warning: passing `double' for converting 1 of ` ns3::Time ns3::NanoSeconds(uint64_t)' Waf: Leaving directory `/cygdrive/c/ws/ns-3-dev/build' Build failed -> task in 'bench-simulator' failed (exit status 1): {task 4287928908L: cxx bench-simulator.cc -> bench-simulator.cc.2.o} ['/usr/bin/g++', '-O0', '-ggdb', '-g3', '-Wall', '-Werror', '-fstrict-aliasing', '-Wstrict-aliasing', '-I.', '-I..', '-DNS3_ASSERT_ENABLE', '-DNS3_LOG_ENABLE', '-DHAVE_SYS_IOCTL_H=1', '-DHAVE_IF_NETS_H=1', '../utils/bench-simulator.cc', '-c ', '-o', 'utils/bench-simulator.cc.2.o']
Can you try adding the following statements. BaseStationNetDevice b; SubscriberStationNetDevice s; CsmaNetDevice c; UanNetDevice u; to the constructor "AnimationInterface"
BaseStationNetDevice b; SubscriberStationNetDevice s; CsmaNetDevice c; UanNetDevice u; NS_UNUSED(b); NS_UNUSED(s); NS_UNUSED(c); NS_UNUSED(u);
Works. But, no offense intended, this is not quite the nicest fix.
Yeah but it has nothing to do with netanim. Unless wad is better documented we need workarounds
At the moment, Alex and I are sort of maintainers for waf. What needs to be done, what is the issue exactly?
1. I don't have working Cygwin setup. ns-3 never compiles due to various compilation warnings. 2. We need to understand why the static/global variables of certain modules mentioned in the wscript are not linked , as mentioned earlier, something like: module = bld.create_ns3_module ('netanim', ['internet', 'mobility', 'wimax', 'wifi', 'csma', 'lte', 'uan']) I thought is sufficient to link modules such as Wimax, but apparently NS_LOG_COMPONENT_DEFINE ("WimaxNetDevice"); is not getting executed. I have seen this in the Visual Studio Environment years back, in which case we force the creation of at least one variable of type WimaxNetDevice to ensure all the static/global variables are initialized.