<html><head><meta http-equiv="Content-Type" content="text/html charset=us-ascii"></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space;" class="">Hi John,<div class=""><br class=""></div><div class="">first of all, I would suggest that you take a look at how an NDN code repository is built and installed on your system. I would also suggest that you take a look at how a compiler and linker work and how you should write wscripts.</div><div class=""><br class=""></div><div class="">For all the opens-source software projects that I have seen so far, there is the common convention that code under the src/ directory is supposed to be modified and compiled, while the compiled code and most probably the included header files are supposed to be under the build/ directory.</div><div class=""><br class=""></div><div class="">It is not clear to me what is wrong in your case. I have followed a similar approach a number of times and it worked fine.</div><div class=""><br class=""></div><div class="">How do you get the Forwarder instance of a simulated node in your simulation scenario?</div><div class=""><br class=""></div><div class="">Thanks,</div><div class=""><br class=""></div><div class=""><div class="">
<div class=""><div class=""><div class=""><span class="" style="float: none; display: inline !important;">Spyridon (Spyros) Mastorakis</span><br class=""><span class="" style="float: none; display: inline !important;">Personal Website: </span><a href="http://cs.ucla.edu/~mastorakis/" class="">http://cs.ucla.edu/~mastorakis/</a><br class=""><span class="" style="float: none; display: inline !important;">Internet Research Laboratory</span><br class=""><span class="" style="float: none; display: inline !important;">Computer Science Department</span><br class=""><span class="" style="float: none; display: inline !important;">UCLA</span></div><div class=""><br class=""></div></div></div></div><div><blockquote type="cite" class=""><div class="">On May 21, 2017, at 3:43 PM, John Baugh <<a href="mailto:jpbaugh@umich.edu" class="">jpbaugh@umich.edu</a>> wrote:</div><br class="Apple-interchange-newline"><div class=""><div dir="auto" class="">Still no progress since last night sadly.<div dir="auto" class=""><br class=""></div><div dir="auto" class="">If any of you have a suggestion or answers to any of my questions below please give your input.  I think I'm fairly close, but I'm missing something I believe.</div><div dir="auto" class=""><br class=""></div><div dir="auto" class="">Thanks</div><div dir="auto" class=""><br class=""></div><div dir="auto" class="">John</div><br class=""><div class="gmail_extra" dir="auto"><br class=""><div class="gmail_quote">On May 21, 2017 2:25 AM, "John Baugh" <<a href="mailto:jpbaugh@umich.edu" class="">jpbaugh@umich.edu</a>> wrote:<br type="attribution" class=""><blockquote class="quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr" class="">Greetings again friends,<div class=""><br class=""></div><div class="">After some good advice from Ashlesh, I was able to get a different error (seems to be a linker error now instead of a compiler error... progress is progress I suppose.)</div><div class=""><br class=""></div><div class="">So, related to this:</div><div class=""><br class=""></div><div class="">1.)  There appear to be multiple waf copies in different directories.  Under what circumstances would you run, say, the waf inside the <b class="">NFD </b>directory as opposed to the one at the top level <b class="">ns-3</b> directory?</div><div class=""><br class=""></div><div class="">2.)  I ran the following from the <b class="">ns-3 </b>directory:</div><div class=""><blockquote style="margin:0 0 0 40px;border:none;padding:0px" class="">* ./waf distclean<br class="">* ./waf configure<br class="">*./waf<br class="">*sudo waf install<br class=""><br class=""><br class=""></blockquote>    If you recall, I modified the <b class="">forwarder.cpp</b> file and the <b class="">forwarder.hpp </b>file in the src/ndnSIM/NFD/daemon/fw directory to contain a <b class="">printMessage</b> method.  I made sure it was public.</div><div class=""><br class=""></div><div class="">    After the ./waf commands aforementioned, I checked the ns-3/build/ns3/ndnSIM/NFD/<wbr class="">daemon/fw directory, and the <b class="">forwarder.hpp </b>file <i class="">does seem to be a copy </i>of the one from the src/ndnSIM/NFD.... directory.  </div><div class=""><br class=""></div><div class="">    But I am <b class="">now getting a linker error:</b></div><div class=""><b class=""><br class=""></b></div><div class="">    "... scenarios/ndn-simple2.cpp:120: undefined reference to 'nfd::Forwarder::printMessage(<wbr class="">)</div><div class="">         collect2: error: ld returned 1 exit status"</div><div class=""><br class=""></div><div class=""><br class=""></div><div class="">Ideas?</div><div class=""><br class=""></div><div class="">Thanks,</div><div class=""><br class=""></div><div class="">John</div></div><div class="elided-text"><div class="gmail_extra"><br class=""><div class="gmail_quote">On Fri, May 19, 2017 at 2:35 AM, John Baugh <span dir="ltr" class=""><<a href="mailto:jpbaugh@umich.edu" target="_blank" class="">jpbaugh@umich.edu</a>></span> wrote:<br class=""><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr" class="">Greetings again friends,<div class=""><br class=""></div><div class="">I'm up working on this trying to get my scenario to work with a custom forwarder again at nearly 3 a.m. <i class="">on my birthday</i>.  I'm not sure if that's dedication or insanity.  ;)</div><div class=""><br class=""></div><div class="">I spent another 4-5 hours trying to figure out this specific problem tonight, but with no luck.  I have found the following:</div><div class=""><br class=""></div><div class="">1.  forwarder.hpp lives in <b class="">both </b>ns-3/build/ns3/ndnSIM/NFD/daem<wbr class="">on/fw <b class="">as well as </b>ns-3/src/ndnSIM/NFD/daemon/fw</div><div class="">     The later also has a forwarder.cpp in it.</div><div class=""><br class=""></div><div class="">2.  Which one of the copies (?) of forwarder.hpp mentioned above am I supposed to change / modify for my scenarios to use it instead of the default one?  Where is the corresponding forwarder.cpp file for the one in ns-3/build path (there is one in the ns-3/src path, but none to be found in ns-3/build path mentioned above)</div><div class=""><br class=""></div><div class="">3.  Why is there a <b class="">waf </b>in so many different directories?  They seem to be specialized to the different components of ndnSIM, such as NFD, ndn-cxx, and specific scenarios -  Perhaps I'm using the wrong one(s)?</div><div class=""><br class=""></div><div class="">4.  My scenarios are still saying that the Forwarder class doesn't have a printMessageForTest method, even though I have it declared in both the copies of forwarder.hpp, and have it defined in forwarder.cpp.  I tried recompiling using ./waf in various directories, and I cannot find a solution to this problem.</div><div class=""><br class=""></div><div class="">I appreciate your patience again.  This is a really irritating situation, and I'm fairly certain there's something simple I'm missing.  Any help would be greatly appreciated.</div><div class=""><br class=""></div><div class="">Thanks,</div><div class=""><br class=""></div><div class="">John</div></div><div class="m_-6744468358324047878HOEnZb"><div class="m_-6744468358324047878h5"><div class="gmail_extra"><br class=""><div class="gmail_quote">On Thu, May 18, 2017 at 2:47 AM, John Baugh <span dir="ltr" class=""><<a href="mailto:jpbaugh@umich.edu" target="_blank" class="">jpbaugh@umich.edu</a>></span> wrote:<br class=""><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr" class="">Greetings ndnSIM friends,<div class=""><br class=""></div><div class=""><br class=""></div><div class="">I've spent the last few days working on trying to modify the Forwarder class (which I did - I modified <b class="">ns-3/src/ndnSIM/NFD/daemon/fw/<wbr class="">forwarder.[hpp, cpp]</b>)</div><div class=""><br class=""></div><div class="">However, ./waf doesn't seem to work properly.  I even did a ./waf clean and ./waf build.  On one of the runs of ./waf I did notice it (apparently?) successfully re-build the forwarder.cpp file.</div><div class=""><br class=""></div><div class="">What I did was add a method (the prototype to .hpp and definition to .cpp) called <b class="">printMessageForTest())</b></div><div class=""><b class=""><br class=""></b></div><div class="">I would assume that after ndnSIM was rebuilt with ./waf that my scenario, which calls printMessageForTest on the forwarder would actually work, but it doesn't recognize it.</div><div class=""><br class=""></div><div class="">Any clue what's going on?</div><div class=""><br class=""></div><div class="">Alternatively, if anyone could give an appropriate procedure for ensuring all changes make it into the system when modifications of actual ndnSIM files are made, it would be appreciated.</div><div class=""><br class=""></div><div class="">Looking forward to hearing from you,</div><div class=""><br class=""></div><div class="">John</div></div>
</blockquote></div><br class=""></div>
</div></div></blockquote></div><br class=""></div>
</div></blockquote></div></div></div></div></blockquote></div><br class=""></div></body></html>