Hi Richard, I am sorry for my late respond. I have added all variables
like: m_ecmpMode, m_flowletGap, m_drillRandomChecks, ECMP_RANDOM,
ECMP_PER_FLOW to the .h file. I set types of all variables as "bool".
However I still got many errors as below. Would you mind to give me any hint to solve this problem?
Rey
-------
[1425/2642] Compiling src/internet/model/ipv4-global-routing.cc
In file included from ../src/internet/model/ipv4-global-routing.cc:32:0:
../src/internet/model/ipv4-global-routing.h: In static member function ‘static ns3::TypeId ns3::Ipv4GlobalRouting::GetTypeId()’:
../src/internet/model/ipv4-global-routing.h:241:8: error: invalid use of member ‘ns3::Ipv4GlobalRouting::ECMP_NONE’ in static member function
bool ECMP_NONE;
^
../src/internet/model/ipv4-global-routing.cc:71:30: error: from this location
EnumValue(ECMP_NONE),
^
In file included from ../src/internet/model/ipv4-global-routing.cc:32:0:
../src/internet/model/ipv4-global-routing.h:241:8: error: invalid use of member ‘ns3::Ipv4GlobalRouting::ECMP_NONE’ in static member function
bool ECMP_NONE;
^
../src/internet/model/ipv4-global-routing.cc:73:36: error: from this location
MakeEnumChecker(ECMP_NONE,"ECMP_NONE",ECMP_RANDOM,"ECMP_RANDOM",
^
In file included from ../src/internet/model/ipv4-global-routing.cc:32:0:
../src/internet/model/ipv4-global-routing.h:242:8: error: invalid use of member ‘ns3::Ipv4GlobalRouting::ECMP_RANDOM’ in static member function
bool ECMP_RANDOM;
^
../src/internet/model/ipv4-global-routing.cc:73:58: error: from this location
MakeEnumChecker(ECMP_NONE,"ECMP_NONE",ECMP_RANDOM,"ECMP_RANDOM",
^
In file included from ../src/internet/model/ipv4-global-routing.cc:32:0:
../src/internet/model/ipv4-global-routing.h:243:8: error: invalid use of member ‘ns3::Ipv4GlobalRouting::ECMP_PER_FLOW’ in static member function
bool ECMP_PER_FLOW;
^
../src/internet/model/ipv4-global-routing.cc:74:5: error: from this location
ECMP_PER_FLOW, "ECMP_PER_FLOW",
^
In file included from ../src/internet/model/ipv4-global-routing.cc:32:0:
../src/internet/model/ipv4-global-routing.h:244:8: error: invalid use of member ‘ns3::Ipv4GlobalRouting::ECMP_RR’ in static member function
bool ECMP_RR;
^
../src/internet/model/ipv4-global-routing.cc:75:12: error: from this location
ECMP_RR, "ECMP_RR",
^
In file included from ../src/internet/model/ipv4-global-routing.cc:32:0:
../src/internet/model/ipv4-global-routing.h:245:8: error: invalid use of member ‘ns3::Ipv4GlobalRouting::ECMP_RANDOM_FLOWLET’ in static member function
bool ECMP_RANDOM_FLOWLET;
^
../src/internet/model/ipv4-global-routing.cc:76:12: error: from this location
ECMP_RANDOM_FLOWLET, "ECMP_RANDOM_FLOWLET",
^
In file included from ../src/internet/model/ipv4-global-routing.cc:32:0:
../src/internet/model/ipv4-global-routing.h:246:8: error: invalid use of member ‘ns3::Ipv4GlobalRouting::ECMP_DRILL’ in static member function
bool ECMP_DRILL;
^
../src/internet/model/ipv4-global-routing.cc:77:12: error: from this location
ECMP_DRILL, "ECMP_DRILL"))
^
../src/internet/model/ipv4-global-routing.cc: In constructor ‘ns3::Ipv4GlobalRouting::Ipv4GlobalRouting()’:
../src/internet/model/ipv4-global-routing.cc:109:3: error: class ‘ns3::Ipv4GlobalRouting’ does not have any field named ‘m_lastInterfaceUsed’
m_lastInterfaceUsed(0),
^
In file included from ../src/internet/model/ipv4-global-routing.cc:32:0:
../src/internet/model/ipv4-global-routing.h:249:8: error: ‘ns3::Ipv4GlobalRouting::m_respondToInterfaceEvents’ will be initialized after [-Werror=reorder]
bool m_respondToInterfaceEvents;
^
../src/internet/model/ipv4-global-routing.h:237:8: error: ‘bool ns3::Ipv4GlobalRouting::m_ecmpMode’ [-Werror=reorder]
bool m_ecmpMode;
^
../src/internet/model/ipv4-global-routing.cc:106:1: error: when initialized here [-Werror=reorder]
Ipv4GlobalRouting::Ipv4GlobalRouting ()
^
In file included from ../src/internet/model/ipv4-global-routing.cc:32:0:
../src/internet/model/ipv4-global-routing.h:240:8: error: ‘ns3::Ipv4GlobalRouting::m_drillMemoryUnits’ will be initialized after [-Werror=reorder]
bool m_drillMemoryUnits;
^
../src/internet/model/ipv4-global-routing.h:239:8: error: ‘bool ns3::Ipv4GlobalRouting::m_drillRandomChecks’ [-Werror=reorder]
bool m_drillRandomChecks;
^
../src/internet/model/ipv4-global-routing.cc:106:1: error: when initialized here [-Werror=reorder]
Ipv4GlobalRouting::Ipv4GlobalRouting ()
^
../src/internet/model/ipv4-global-routing.cc:123:3: error: ‘m_seed’ was not declared in this scope
m_seed = m_rand->GetInteger (0,(uint32_t)-1);
^
../src/internet/model/ipv4-global-routing.cc:128:3: error: ‘hasher’ was not declared in this scope
hasher = Hasher();
^
../src/internet/model/ipv4-global-routing.cc: At global scope:
../src/internet/model/ipv4-global-routing.cc:201:85: error: no ‘uint64_t ns3::Ipv4GlobalRouting::GetFlowHash(const ns3::Ipv4Header&, ns3::Ptr<const ns3::Packet>)’ member function declared in class ‘ns3::Ipv4GlobalRouting’
Ipv4GlobalRouting::GetFlowHash(const Ipv4Header &header, Ptr<const Packet> ipPayload)
^
../src/internet/model/ipv4-global-routing.cc:267:86: error: no ‘std::string ns3::Ipv4GlobalRouting::GetFlowTuple(const ns3::Ipv4Header&, ns3::Ptr<const ns3::Packet>)’ member function declared in class ‘ns3::Ipv4GlobalRouting’
Ipv4GlobalRouting::GetFlowTuple(const Ipv4Header &header, Ptr<const Packet> ipPayload)
^
../src/internet/model/ipv4-global-routing.cc:312:65: error: no ‘uint32_t ns3::Ipv4GlobalRouting::GetNextInterface(uint32_t)’ member function declared in class ‘ns3::Ipv4GlobalRouting’
Ipv4GlobalRouting::GetNextInterface(uint32_t m_lastInterfaceUsed)
^
../src/internet/model/ipv4-global-routing.cc:322:110: error: no ‘uint32_t ns3::Ipv4GlobalRouting::GetQueueSize(std::vector<ns3::Ipv4RoutingTableEntry*>, uint32_t)’ member function declared in class ‘ns3::Ipv4GlobalRouting’
uint32_t Ipv4GlobalRouting::GetQueueSize(std::vector<Ipv4RoutingTableEntry*> allRoutes, uint32_t selectIndex ){
^
../src/internet/model/ipv4-global-routing.cc:451:1: error: prototype for ‘ns3::Ptr<ns3::Ipv4Route> ns3::Ipv4GlobalRouting::LookupGlobal(const ns3::Ipv4Header&, ns3::Ptr<const ns3::Packet>, ns3::Ptr<ns3::NetDevice>)’ does not match any in class ‘ns3::Ipv4GlobalRouting’
Ipv4GlobalRouting::LookupGlobal (const Ipv4Header &header, Ptr<const Packet> ipPayload, Ptr<NetDevice> oif)
^
../src/internet/model/ipv4-global-routing.cc:342:1: error: candidate is: ns3::Ptr<ns3::Ipv4Route> ns3::Ipv4GlobalRouting::LookupGlobal(ns3::Ipv4Address, ns3::Ptr<ns3::NetDevice>)
Ipv4GlobalRouting::LookupGlobal (Ipv4Address dest, Ptr<NetDevice> oif)
^
../src/internet/model/ipv4-global-routing.cc:867:1: error: prototype for ‘void ns3::Ipv4GlobalRouting::PrintRoutingTable(ns3::Ptr<ns3::OutputStreamWrapper>, ns3::Time::Unit) const’ does not match any in class ‘ns3::Ipv4GlobalRouting’
Ipv4GlobalRouting::PrintRoutingTable (Ptr<OutputStreamWrapper> stream, Time::Unit unit) const
^
In file included from ../src/internet/model/ipv4-global-routing.cc:32:0:
../src/internet/model/ipv4-global-routing.h:101:16: error: candidate is: virtual void ns3::Ipv4GlobalRouting::PrintRoutingTable(ns3::Ptr<ns3::OutputStreamWrapper>) const
virtual void PrintRoutingTable (Ptr<OutputStreamWrapper> stream) const;
^
../src/internet/model/ipv4-global-routing.cc: In member function ‘virtual ns3::Ptr<ns3::Ipv4Route> ns3::Ipv4GlobalRouting::RouteOutput(ns3::Ptr<ns3::Packet>, const ns3::Ipv4Header&, ns3::Ptr<ns3::NetDevice>, ns3::Socket::SocketErrno&)’:
../src/internet/model/ipv4-global-routing.cc:938:56: error: no matching function for call to ‘ns3::Ipv4GlobalRouting::LookupGlobal(const ns3::Ipv4Header&, ns3::Ptr<ns3::Packet>&, ns3::Ptr<ns3::NetDevice>&)’
Ptr<Ipv4Route> rtentry = LookupGlobal (header, p, oif);
^
../src/internet/model/ipv4-global-routing.cc:938:56: note: candidate is:
../src/internet/model/ipv4-global-routing.cc:342:1: note: ns3::Ptr<ns3::Ipv4Route> ns3::Ipv4GlobalRouting::LookupGlobal(ns3::Ipv4Address, ns3::Ptr<ns3::NetDevice>)
Ipv4GlobalRouting::LookupGlobal (Ipv4Address dest, Ptr<NetDevice> oif)
^
../src/internet/model/ipv4-global-routing.cc:342:1: note: candidate expects 2 arguments, 3 provided
../src/internet/model/ipv4-global-routing.cc: In member function ‘virtual bool ns3::Ipv4GlobalRouting::RouteInput(ns3::Ptr<const ns3::Packet>, const ns3::Ipv4Header&, ns3::Ptr<const ns3::NetDevice>, ns3::Ipv4RoutingProtocol::UnicastForwardCallback, ns3::Ipv4RoutingProtocol::MulticastForwardCallback, ns3::Ipv4RoutingProtocol::LocalDeliverCallback, ns3::Ipv4RoutingProtocol::ErrorCallback)’:
../src/internet/model/ipv4-global-routing.cc:987:51: error: no matching function for call to ‘ns3::Ipv4GlobalRouting::LookupGlobal(const ns3::Ipv4Header&, ns3::Ptr<const ns3::Packet>&)’
Ptr<Ipv4Route> rtentry = LookupGlobal (header, p);
^
../src/internet/model/ipv4-global-routing.cc:987:51: note: candidate is:
../src/internet/model/ipv4-global-routing.cc:342:1: note: ns3::Ptr<ns3::Ipv4Route> ns3::Ipv4GlobalRouting::LookupGlobal(ns3::Ipv4Address, ns3::Ptr<ns3::NetDevice>)
Ipv4GlobalRouting::LookupGlobal (Ipv4Address dest, Ptr<NetDevice> oif)
^
../src/internet/model/ipv4-global-routing.cc:342:1: note: no known conversion for argument 1 from ‘const ns3::Ipv4Header’ to ‘ns3::Ipv4Address’
cc1plus: all warnings being treated as errors
Waf: Leaving directory `/home/jedi/ns3/ns-allinone-3.26/ns-3.26/build'
Build failed
-> task in 'ns3-internet' failed (exit status 1):
{task 3066466380L: cxx ipv4-global-routing.cc -> ipv4-global-routing.cc.1.o}
['/usr/bin/g++', '-O0', '-ggdb', '-g3', '-Wall', '-Werror', '-std=c++11', '-Wno-error=deprecated-declarations', '-fstrict-aliasing', '-Wstrict-aliasing', '-fPIC', '-pthread', '-I.', '-I..', '-DNS3_BUILD_PROFILE_DEBUG', '-DNS3_ASSERT_ENABLE', '-DNS3_LOG_ENABLE', '-DHAVE_SYS_IOCTL_H=1', '-DHAVE_IF_NETS_H=1', '-DHAVE_NET_ETHERNET_H=1', '-DHAVE_PACKET_H=1', '-DHAVE_IF_TUN_H=1', '-DHAVE_GSL=1', '-DHAVE_SQLITE3=1', '../src/internet/model/ipv4-global-routing.cc', '-c', '-o', '/home/jedi/ns3/ns-allinone-3.26/ns-3.26/build/src/internet/model/ipv4-global-routing.cc.1.o']