Linux - SoftwareThis forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.
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.
Dear friends, I tried to implement GPRS in ns 2.33 & ubuntu linux 10.10 with the following commannds
cd ns-allinone-2.33/
cd ns-2.33/
patch -p1 < ns-2.33-hls.patch
tar xvf hls-files-ns233.tar.gz
cd ../
./install
But the following errors appeared
common/packet.h:391: error: ‘PT_LOCS’ was not declared in this scope
common/packet.h:394: error: ‘PT_HLS’ was not declared in this scope
common/packet.h:397: error: ‘PT_GPSR’ was not declared in this scope
common/packet.h:400: warning: deprecated conversion from string constant to ‘char*’
common/scheduler.cc: In member function ‘virtual int Scheduler::command(int, const char* const*)’:
common/scheduler.cc:216: warning: deprecated conversion from string constant to ‘char*’
make: *** [common/scheduler.o] Error 1
Ns make failed!
See http://www.isi.edu/nsnam/ns/ns-problems.html for problems
khalid@khalid-linux:~/ns-allinone-2.33$
How to implement GPSR in ns 2.33 & ubuntu linux 10.10
[QUOTE=knudfl;5072982]#1 + #3 .
In Ubuntu 10.10, you will have to handle the `./install' command this way :
$ export CC=gcc-4.1 CXX=g++-4.1 && .install
You will of course have to install compilers version 4.1.2 :
$ sudo apt-get install g++-4
Dear Mr.Knudfl, I tried to install tyhe compilers version 4.1.2 but the following error appeared. May you help me about how can I override this error.
bash: :/usr/X11R6/lib:/usr/local/lib: No such file or directory
khalid@khalid-linux:~$ export CC=gcc-4.1 CXX=g++-4.1
khalid@khalid-linux:~$ ./install
bash: ./install: No such file or directory
Dear Mr.Knudfl, I did all the steps to incorporate GPSR inside ns 2.33 but the following error appeared.
locservices/ls_queued_timer.cc: In member function ‘void QueuedTimer:rintQueue()’:
locservices/ls_queued_timer.cc:307: error: cast from ‘void*’ to ‘int’ loses precision
locservices/ls_queued_timer.cc: In member function ‘void TimerHeap:rintTable()’:
locservices/ls_queued_timer.cc:472: error: cast from ‘void*’ to ‘int’ loses precision
make: *** [locservices/ls_queued_timer.o] Error 1
Ns make failed!
Distribution: PCLinuxOS2023 Fedora38 + 50+ other Linux OS, for test only.
Posts: 17,493
Rep:
# 7 .
Quote:
locservices/ls_queued_timer.cc:307: error: cast from ‘void*’ to ‘int’ loses precision
Looks like "patch -p1 < ns-2.33-hls.patch" failed.
I have made a new "patch package" with everything included / patched :
{ The ns-2.33-hls.patch, hls-files-ns233.tar.gz, Makefile.in } → →
gpsr-hls-ns233-patching.tar.bz2 ( 5.3 MB ) → https://drive.google.com/file/d/0B7S...it?usp=sharing
The new build instructions are then much simpler :
$ cd ns-allinone-2.33/
$ tar xvf gpsr-hls-ns233-patching.tar.bz2
$ export CC=gcc-4.1 CXX=g++-4.1
$ ./install
I have replaced ns-2.33 with the one that you gave and did the following :
$ cd ns-allinone-2.33/
$ tar xvf gpsr-hls-ns233-patching.tar.bz2
$ export CC=gcc-4.1 CXX=g++-4.1
$ ./install
but we have same errors
locservices/ls_queued_timer.cc: In member function ‘void QueuedTimer:rintQueue()’:
locservices/ls_queued_timer.cc:307: error: cast from ‘void*’ to ‘int’ loses precision
locservices/ls_queued_timer.cc: In member function ‘void TimerHeap:rintTable()’:
locservices/ls_queued_timer.cc:472: error: cast from ‘void*’ to ‘int’ loses precision
make: *** [locservices/ls_queued_timer.o] Error 1
Ns make failed!
Dear Mr.Knudfl, I did the commands in Quote 10 and the following results for each command are:
for No1: $ ls /usr/bin/gcc* /usr/bin/gcc /usr/bin/gcc-4.3 /usr/bin/gccbug-4.1 /usr/bin/gcc-4.1 /usr/bin/gcc-4.4
for No2: ls /usr/bin/g++ /usr/bin/g++
For No3. which gcc-4.1 /usr/bin/gcc-4.1
for No4. which g++-4.1 /usr/bin/g++-4.1
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.