[ndnSIM] ndnSIM Digest, Vol 24, Issue 6

ioannoa ioannoa at scss.tcd.ie
Wed Nov 26 14:36:07 PST 2014


Hello all,

I am trying to implement a forwarding protocol but I fell into a few 
compilation errors, i.e.

Waf: Entering directory 
`/home/ioannoa/ndnSIM/ndnSIM-sample-topologies/build'
[1/2] cxx: scenarios/ndn-annotated-topo-normal.cc -> 
build/scenarios/ndn-annotated-topo-normal.cc.2.o
[2/2] cxxprogram: build/scenarios/ndn-annotated-topo-normal.cc.2.o -> 
build/ndn-annotated-topo-normal
scenarios/ndn-annotated-topo-normal.cc.2.o: In function `main':

/home/ioannoa/ndnSIM/ndnSIM-sample-topologies/build/../scenarios/ndn-annotated-topo-normal.cc:97: 
undefined reference to 
`ns3::ndn::StackHelper::SetTFib(std::basic_string<char, 
std::char_traits<char>, std::allocator<char> > const&, 
std::basic_string<char, std::char_traits<char>, std::allocator<char> > 
const&, std::basic_string<char, std::char_traits<char>, 
std::allocator<char> > const&, std::basic_string<char, 
std::char_traits<char>, std::allocator<char> > const&, 
std::basic_string<char, std::char_traits<char>, std::allocator<char> > 
const&, std::basic_string<char, std::char_traits<char>, 
std::allocator<char> > const&, std::basic_string<char, 
std::char_traits<char>, std::allocator<char> > const&, 
std::basic_string<char, std::char_traits<char>, std::allocator<char> > 
const&, std::basic_string<char, std::char_traits<char>, 
std::allocator<char> > const&)'
/home/ioannoa/ndnSIM/ndnSIM-sample-topologies/build/../scenarios/ndn-annotated-topo-normal.cc:98: 
undefined reference to 
`ns3::ndn::StackHelper::SetConx(std::basic_string<char, 
std::char_traits<char>, std::allocator<char> > const&, 
std::basic_string<char, std::char_traits<char>, std::allocator<char> > 
const&, std::basic_string<char, std::char_traits<char>, 
std::allocator<char> > const&, std::basic_string<char, 
std::char_traits<char>, std::allocator<char> > const&, 
std::basic_string<char, std::char_traits<char>, std::allocator<char> > 
const&, std::basic_string<char, std::char_traits<char>, 
std::allocator<char> > const&, std::basic_string<char, 
std::char_traits<char>, std::allocator<char> > const&, 
std::basic_string<char, std::char_traits<char>, std::allocator<char> > 
const&, std::basic_string<char, std::char_traits<char>, 
std::allocator<char> > const&)'
collect2: ld returned 1 exit status


In my simulation file I include the below:

#include "ns3/ndnSIM/model/fib/ndn-tfib.h"
#include "ns3/ndnSIM/model/conx/ndn-conx.h"

where conx is a new folder containing the ndn-conx.h and ndn-conx.cc 
files. Furthemore, in my StackHelper (.h & .cc) files I have included 
both headers and defined the corresponding functions for the 
installation on a node similar to pit, fib etc. Could, please someone 
point me out what my error may be? My simulation runs fine on my laptop 
(MAC OS X 10.8) but fails when I try it on Ubuntu 12.04.

Also, I get some mistakes if I do not disable python.

src/ndnSIM/bindings/ns3module.cc: In function ‘int 
_wrap_PyNs3NdnPitEntry__tp_init__1(PyNs3NdnPitEntry*, PyObject*, 
PyObject*, PyObject**)’:
src/ndnSIM/bindings/ns3module.cc:3320:171: error: no matching function 
for call to ‘ns3::ndn::pit::Entry::Entry(ns3::ndn::Pit&, 
ns3::Ptr<ns3::ndn::Interest>, ns3::Ptr<ns3::ndn::fib::Entry>)’
src/ndnSIM/bindings/ns3module.cc:3320:171: note: candidates are:
./ns3/ndn-pit-entry.h:73:5: note: 
ns3::ndn::pit::Entry::Entry(ns3::ndn::Pit&, ns3::Ptr<const 
ns3::ndn::Interest>, ns3::Ptr<ns3::ndn::tfib::Entry>, bool)
./ns3/ndn-pit-entry.h:73:5: note:   candidate expects 4 arguments, 3 
provided
./ns3/ndn-pit-entry.h:63:3: note: 
ns3::ndn::pit::Entry::Entry(ns3::ndn::Pit&, ns3::Ptr<const 
ns3::ndn::Interest>, ns3::Ptr<ns3::ndn::fib::Entry>, bool)
./ns3/ndn-pit-entry.h:63:3: note:   candidate expects 4 arguments, 3 
provided
./ns3/ndn-pit-entry.h:44:7: note: ns3::ndn::pit::Entry::Entry(const 
ns3::ndn::pit::Entry&)
./ns3/ndn-pit-entry.h:44:7: note:   candidate expects 1 argument, 3 
provided
Waf: Leaving directory `/home/ioannoa/ndnSIM/ns-3/build'


The reason is that I have inserted a new bool field in a pitEntry that 
specifies whether my entry corresponds to a fib entry or to a tfib 
entry, (i.e. tfib table holds temporal entries for forwarding).Is 
modulegen__gcc_LP64.py the corresponding python file that I should 
change in order to make this work as well?

Many thanks,
Andriana.



More information about the ndnSIM mailing list