LinuxQuestions.org
Latest LQ Deal: Linux Power User Bundle
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 01-10-2012, 12:44 PM   #1
shidayat
LQ Newbie
 
Registered: Mar 2011
Posts: 11

Rep: Reputation: 0
Help NS2.28 misc.cc error: 'strtoq' undeclared


Hello, I'm building NS2.28 with AEDCF module from ftp://ftp-sop.inria.fr/rodeo/qni/ns-aedcf.tar.gz

I'm following the instruction from the source,
make depend --> OK
but when make install this error come up
Code:
misc.cc: In member function 'virtual int Add64Command::command(int, const char*const*)':
misc.cc:64: error: 'strtoq' undeclared (first use this function)
misc.cc:64: error: (Each undeclared identifier is reported only once for each function it appears in.)
make: *** [misc.o] Error 1
I attach misc.cc as misc.txt

Can someone give some light please...
Attached Files
File Type: txt misc.txt (4.3 KB, 4 views)
 
Old 01-11-2012, 01:45 PM   #2
smallpond
Senior Member
 
Registered: Feb 2011
Location: Massachusetts, USA
Distribution: CentOS 6 (pre-systemd)
Posts: 2,609

Rep: Reputation: 702Reputation: 702Reputation: 702Reputation: 702Reputation: 702Reputation: 702Reputation: 702
STRTOI64 is probably just a macro which calls strtoq. strtoq should be defined in /usr/include/stdlib.h. See if it is.
 
1 members found this post helpful.
Old 01-11-2012, 10:15 PM   #3
shidayat
LQ Newbie
 
Registered: Mar 2011
Posts: 11

Original Poster
Rep: Reputation: 0
thank you smallpond, i have added strtoq in stdlib and misc.cc problem was solved.
but now i'm stuck again
Code:
flowmon.cc: In constructor 'Flow::Flow()':
flowmon.cc:62: error: call of overloaded 'bind(const char[5], nsaddr_t*)' is ambiguous
....
make: ***[flowmon.o] Error 1
i have search in the flowmon.cc whether it has duplicate Flow() functions or not,
and I just find one Flow() so what makes it ambiguous?

this flowmon.cc
Attached Files
File Type: txt flowmon.txt (18.4 KB, 1 views)
 
Old 01-12-2012, 07:43 AM   #4
knudfl
LQ 5k Club
 
Registered: Jan 2008
Location: Copenhagen, DK
Distribution: pclos2016, Slack14.1 Deb Jessie, + 50+ other Linux OS, for test only.
Posts: 16,276

Rep: Reputation: 3154Reputation: 3154Reputation: 3154Reputation: 3154Reputation: 3154Reputation: 3154Reputation: 3154Reputation: 3154Reputation: 3154Reputation: 3154Reputation: 3154
The package ns-aedcf.tar.gz from
ftp://ftp-sop.inria.fr/rodeo/qni/
... is actually a complete 1999 ns-2.1b7(a), + some 1999 binary libraries
from ns-allinone-2.1b7(a).

'ns-2.1b7' http://www.isi.edu/nsnam/dist/
( ns-src-2.1b7a.tar.gz , ns-allinone-2.1b7a.tar.gz, etc.)
Meant to be compiled with gcc/g++ version 2.8 ?

You will probable have to edit a lot of files to use an OS / a compiler
from this century.
(No indications, that anybody have compiled an ns-2.1b7 for many years.)

.

Last edited by knudfl; 01-12-2012 at 07:44 AM.
 
Old 01-20-2012, 01:31 AM   #5
shidayat
LQ Newbie
 
Registered: Mar 2011
Posts: 11

Original Poster
Rep: Reputation: 0
flowmon.cc problem solved...
by adding this code on tclcl.h line 177
Code:
void bind(const char* var, int32_t* val);
and here another error
Code:
imep/rxmit_queue.h:61: error: friend declaration requires class-key, i.e. 'friend struct ReXmitQ'
make: *** [imep/imep.o] Error 1
solved adding this code in imep/rxmit_queue.h line 61
Code:
friend class ReXmitQ;
comes another error
Code:
diffusion/diffusion.cc:407: error: default argument given for parameter 2 of 'void DiffusionAgent::MACsend(Packet*, double)'
diffusion/diffusion.h:152: error: after previous specification in 'void DiffusionAgent::MACsend(Packet*, double)'
make: *** [diffusion/diffusion.o] Error 1
working on it...

Last edited by shidayat; 01-20-2012 at 01:41 AM. Reason: come other error
 
Old 01-20-2012, 02:01 AM   #6
shidayat
LQ Newbie
 
Registered: Mar 2011
Posts: 11

Original Poster
Rep: Reputation: 0
solved diffusion.cc, diffusion.cc line 406
Code:
void DiffusionAgent::MACsend(Packet *pkt, Time delay)
{
  delay = 0;
and diffusion.h line 152
Code:
void MACsend(Packet *pkt, Time delay);
same error on:
diffusion/flooding.cc:263 and diffusion/omni_mcast.cc:389
diffusion/flooding.h:97 and diffusion/omni_mcast.h:167

solving like on diffusion.cc and diffusion.h

another error:
Code:
/home/a/aedcf/ns-aedcf/bin/CYGWIN_NT-5.1/tclsh8.0: not found
make: *** [gen/version.c] Error 127
searching again...
 
Old 01-27-2012, 10:51 PM   #7
shidayat
LQ Newbie
 
Registered: Mar 2011
Posts: 11

Original Poster
Rep: Reputation: 0
solved by creating empty file version.c at gen/
and same problem on ns_tcl.cc

another error:
Code:
/usr/lib/gcc-lib/i686-pc-cygwin/3.3.1/../../../../i686-pc-cygwin/bin/ld: cannot find -ltclcl
collect2: ld returned 1 exit status
make: *** [ns] Error 1
any help would be appreciated...
 
Old 01-28-2012, 05:36 AM   #8
knudfl
LQ 5k Club
 
Registered: Jan 2008
Location: Copenhagen, DK
Distribution: pclos2016, Slack14.1 Deb Jessie, + 50+ other Linux OS, for test only.
Posts: 16,276

Rep: Reputation: 3154Reputation: 3154Reputation: 3154Reputation: 3154Reputation: 3154Reputation: 3154Reputation: 3154Reputation: 3154Reputation: 3154Reputation: 3154Reputation: 3154
# 7
Quote:
cannot find -ltclcl
Means : Cannot find libtclcl.a or libtclcl.so
 
Old 02-03-2012, 05:16 PM   #9
shidayat
LQ Newbie
 
Registered: Mar 2011
Posts: 11

Original Poster
Rep: Reputation: 0
Quote:
Originally Posted by knudfl View Post
# 7


Means : Cannot find libtclcl.a or libtclcl.so
where should I put libtclcl.a or libtclcl.so ?
I found libtclcl.a at ns-aedcf/lib/Linux and ns-aedcf/lib/SunOS is it the file that you refer?
 
Old 02-03-2012, 06:47 PM   #10
shidayat
LQ Newbie
 
Registered: Mar 2011
Posts: 11

Original Poster
Rep: Reputation: 0
I make a copy of directory lib/Linux to lib/CYGWIN_NT-5.1
after this step ltclcl and lotcl solved but ltk8.0 problem come up
is it because different filetype? libtclcl.a and libotcl.a while libtk8.0.so
 
Old 02-04-2012, 04:29 AM   #11
knudfl
LQ 5k Club
 
Registered: Jan 2008
Location: Copenhagen, DK
Distribution: pclos2016, Slack14.1 Deb Jessie, + 50+ other Linux OS, for test only.
Posts: 16,276

Rep: Reputation: 3154Reputation: 3154Reputation: 3154Reputation: 3154Reputation: 3154Reputation: 3154Reputation: 3154Reputation: 3154Reputation: 3154Reputation: 3154Reputation: 3154
Are you using an ancient version of Tcl ?

ns-allinone-2.28 would have like ns-allinone-2.28/lib/libtk8.4.a
( This is on Linux, may be Cygwin makes it different ? ? )
 
Old 03-12-2012, 07:24 PM   #12
Reagen
LQ Newbie
 
Registered: Mar 2012
Posts: 2

Rep: Reputation: Disabled
Hello i'm building ns 2.28 with AEDCF from ftp://ftp-sop.inria.fr/rodeo/qni/ns-aedcf.tar.gz
same like "shidayat"

I'm following the instrution from the source.
1.Make depend -> success
2.Make install -> i've got problem.
The errors that i've got :
Quote:

plm/cbr-traffic-PP.o: In function `CBR_PP_TrafficClass::~CBR_PP_TrafficClass [in-charge deleting]()':
cbr-traffic-PP.cc.gnu.linkonce.t._ZN19CBR_PP_TrafficClassD0Ev+0x16): undefined reference to `TclClass::~TclClass [not-in-charge]()'
plm/cbr-traffic-PP.o: In function `CBR_PP_TrafficClass::~CBR_PP_TrafficClass [in-charge]()':
cbr-traffic-PP.cc.gnu.linkonce.t._ZN19CBR_PP_TrafficClassD1Ev+0x13): undefined reference to `TclClass::~TclClass [not-in-charge]()'
plm/cbr-traffic-PP.o.gnu.linkonce.r._ZTI19CBR_PP_TrafficClass+0x8): undefined reference to `typeinfo for TclClass'
collect2: ld returned 1 exit status
make: *** [ns] Error 1
Can someone give me somelight. I've searched, but i don't know what i must to do with "gnu.linkonce"

I'm using ubuntu 9.04 with gcc 3.3 and g++ 3.3
And this is my link library :
Quote:
ubuntu@ubuntu-laptop:~/aedcf/ns-aedcf/ns2$ ls -l /usr/lib/libstdc++*
-rw-r--r-- 1 root root 256240 2000-02-19 22:41 /usr/lib/libstdc++-2-libc6.1-1-2.9.0.so
-rw-r--r-- 1 root root 288540 2004-09-29 21:08 /usr/lib/libstdc++-3-libc6.2-2-2.10.0.so
lrwxrwxrwx 1 root root 30 2012-03-13 05:50 /usr/lib/libstdc++-libc6.1-1.so.2 -> libstdc++-2-libc6.1-1-2.9.0.so
lrwxrwxrwx 1 root root 31 2012-03-13 05:16 /usr/lib/libstdc++-libc6.2-2.so.3 -> libstdc++-3-libc6.2-2-2.10.0.so
lrwxrwxrwx 1 root root 18 2012-03-13 02:47 /usr/lib/libstdc++.so.5 -> libstdc++.so.5.0.7
-rw-r--r-- 1 root root 737192 2008-05-10 13:18 /usr/lib/libstdc++.so.5.0.7
lrwxrwxrwx 1 root root 19 2012-03-13 05:16 /usr/lib/libstdc++.so.6 -> libstdc++.so.6.0.13
-rw-r--r-- 1 root root 975012 2010-11-14 19:30 /usr/lib/libstdc++.so.6.0.13
Please..Any help would be appreciated
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
[SOLVED] getting an error -- undeclared CLOCK_PROCESS_CPUTIME_ID iqra Programming 9 07-09-2010 05:05 PM
[SOLVED] observation or possibly a bug in font-misc-misc install timetraveler Slackware 9 05-11-2010 05:28 PM
error: ‘LOGGING_FACILITY’ undeclared (first use in this function) nasim751 Linux - Software 1 04-19-2008 06:55 AM
`X_' undeclared error while compiling GTK mohamedkaabi Solaris / OpenSolaris 1 05-24-2006 02:56 AM
error in compilation gives `TIOCGDEV' undeclared cranium2004 Linux - Software 1 03-09-2006 08:27 AM


All times are GMT -5. The time now is 06:45 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration