“undefined reference to `hdr_aodv::offset_'” error in NS 2.35
Linux - NetworkingThis forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
“undefined reference to `hdr_aodv::offset_'” error in NS 2.35
I am trying to make some improvements on AODV routing protocol using NS 2.35. I have made some changes in aodv.cc and aodv.h file. For making the changes effective, I have made the following three commands from the terminal inside NS 2.35 folder:
1. sudo su
2.make clean
3.make
Now I am having the following error:
trace/cmu-trace.o: In function `CMUTrace::format_aodv(Packet*, int)':
cmu-trace.cc: (.text+0x18b7): undefined reference to `hdr_aodv:: offset_'
What is the solutions of this?
For more clarification I am providing the .cc file link here:
Distribution: PCLinuxOS2023 Fedora38 + 50+ other Linux OS, for test only.
Posts: 17,511
Rep:
AODV.cc and AODV.h : The file names are aodv.cc, aodv.h .
? Why are you running as root = 'sudo su', when you are building ns2 ?
Most convenient setup is /home/<user>/ns2/ns-allinone-2.3x/.
No ns2 root commands are allowed, except 'make install' and 'cp ns-name /usr/local/bin/'.
Files : Your modified aodv.h is missing.
And the changes are missing, i.e. what did you edit, and which line numbers :
The diff command can generate the changes ...
diff -Naur aodv.cc-orig aodv.cc >> changes-aodv.cc.txt
diff -Naur aodv.h-orig aodv.h >> changes-aodv.h.txt
P.S. : Why the tag "ns2 ns234", when the above says ns-2.35 ?
Surplus tags : "linux command", "networking" (The 'ns2' tag will do.)
“undefined reference to `hdr_aodv::offset_'” error in NS 2.35
Quote:
Originally Posted by knudfl
AODV.cc and AODV.h : The file names are aodv.cc, aodv.h .
? Why are you running as root = 'sudo su', when you are building ns2 ?
Most convenient setup is /home/<user>/ns2/ns-allinone-2.3x/.
No ns2 root commands are allowed, except 'make install' and 'cp ns-name /usr/local/bin/'.
Files : Your modified aodv.h is missing.
And the changes are missing, i.e. what did you edit, and which line numbers :
The diff command can generate the changes ...
diff -Naur aodv.cc-orig aodv.cc >> changes-aodv.cc.txt
diff -Naur aodv.h-orig aodv.h >> changes-aodv.h.txt
P.S. : Why the tag "ns2 ns234", when the above says ns-2.35 ?
Surplus tags : "linux command", "networking" (The 'ns2' tag will do.)
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.