Linux - NewbieThis 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
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.
Post# 15
This is what i m getting when i run commands:
najmaismat@ubuntu:~$ sudo apt-get install gcc-4.1
Reading package lists... Done
Building dependency tree
Reading state information... Done
gcc-4.1 is already the newest version.
The following packages were automatically installed and are no longer required:
libaccess-bridge-java nspluginwrapper libaccess-bridge-java-jni
linux-headers-2.6.32-33 linux-headers-2.6.32-33-generic
Use 'apt-get autoremove' to remove them.
0 upgraded, 0 newly installed, 0 to remove and 49 not upgraded.
najmaismat@ubuntu:~$ sudo apt-get install g++-4.1
Reading package lists... Done
Building dependency tree
Reading state information... Done
g++-4.1 is already the newest version.
The following packages were automatically installed and are no longer required:
libaccess-bridge-java nspluginwrapper libaccess-bridge-java-jni
linux-headers-2.6.32-33 linux-headers-2.6.32-33-generic
Use 'apt-get autoremove' to remove them.
0 upgraded, 0 newly installed, 0 to remove and 49 not upgraded.
Post#16
when I run this command [$ export CC=gcc-4.1 CXX=g++-4.1 && ./install]
i m getting this getting this result
root@ubuntu:/home/najmaismat# export CC=gcc-4.1 CXX=g++-4.1 && ./install
bash: ./install: No such file or directory
and for Configuring ns-2.29/ [$ export CC=gcc-4.1 CXX=g++-4.1 && ./configure]
the this is the o/p show in code window:
Code:
root@ubuntu:/home/najmaismat/ns-allinone-2.29/ns-2.29# export CXX=g++41 && ./configure
No .configure file found in current directory
Continuing with default options...
checking build system type... x86_64-unknown-linux-gnu
checking host system type... x86_64-unknown-linux-gnu
checking target system type... x86_64-unknown-linux-gnu
checking for gcc... gcc-4.1
checking for C compiler default output file name... a.out
checking whether the C compiler works... yes
checking whether we are cross compiling... no
checking for suffix of executables...
checking for suffix of object files... o
checking whether we are using the GNU C compiler... yes
checking whether gcc-4.1 accepts -g... yes
checking for gcc-4.1 option to accept ANSI C... none needed
checking whether we are using the GNU C++ compiler... no
checking whether g++41 accepts -g... no
checking how to run the C preprocessor... gcc-4.1 -E
checking for egrep... grep -E
checking for ANSI C header files... yes
checking for sys/types.h... yes
checking for sys/stat.h... yes
checking for stdlib.h... yes
checking for string.h... yes
checking for memory.h... yes
checking for strings.h... yes
checking for inttypes.h... yes
checking for stdint.h... yes
checking for unistd.h... yes
checking for string.h... (cached) yes
checking for main in -lXbsd... no
checking for socket in -lsocket... no
checking for gethostbyname in -lnsl... yes
checking for dcgettext in -lintl... no
checking for getnodebyname in -ldnet_stub... no
checking if C++ libraries work without any namespace... no
checking if C++ libraries work with namespace std... no
checking if STL works without any namespace... no
checking if STL works with namespace std... no
checking if STL works with namespace stl... no
checking should use STL... no, couldn't find STL
checking for tcl.h... -I../include
checking for libtcl8.4... -L../lib -ltcl8.4
checking for init.tcl... ../lib/tcl8.4
checking for tclsh8.4.11... no
checking for tclsh8.4... ../bin/tclsh8.4
checking for tk.h... -I../include
checking for libtk8.4... -L../lib -ltk8.4
checking for tk.tcl... ../lib/tk8.4
checking for otcl.h... -I../otcl-1.11
checking for libotcl1.11... -L../otcl-1.11 -lotcl
checking for tclcl.h... -I../tclcl-1.17
checking for libtclcl... -L../tclcl-1.17 -ltclcl
checking for tcl2c++... ../tclcl-1.17
checking for libtcldbg... no
checking dmalloc... not requested with --with-dmalloc
checking for perl... /usr/bin
checking for ANSI C header files... (cached) yes
checking arpa/inet.h usability... yes
checking arpa/inet.h presence... yes
checking for arpa/inet.h... yes
checking fenv.h usability... yes
checking fenv.h presence... yes
checking for fenv.h... yes
checking netinet/in.h usability... yes
checking netinet/in.h presence... yes
checking for netinet/in.h... yes
checking for string.h... (cached) yes
checking for strings.h... (cached) yes
checking time.h usability... yes
checking time.h presence... yes
checking for time.h... yes
checking for unistd.h... (cached) yes
checking net/ethernet.h usability... yes
checking net/ethernet.h presence... yes
checking for net/ethernet.h... yes
checking for main in -lm... yes
checking for bcopy... yes
checking for bzero... yes
checking for fesetprecision... no
checking for feenableexcept... yes
checking for getrusage... yes
checking for sbrk... yes
checking for snprintf... yes
checking return type of random... long
checking for int8_t... yes
checking for int16_t... yes
checking for int32_t... yes
checking for u_int8_t... yes
checking for u_int16_t... yes
checking for u_int32_t... yes
checking for u_char... yes
checking for u_int... yes
checking for strtoq... yes
checking for strtoll... yes
checking for long... yes
checking size of long... 8
checking for strtol... yes
checking for __int64_t... no
checking for long long... yes
checking for int64_t... yes
checking which kind of 64-bit int to use... int64_t
checking for struct ether_header... found
checking for struct ether_addr... found
checking for addr2ascii... no
checking for Linux compliant tcphdr... found
checking for BSD compliant tcphdr... not found
checking for socklen_t... yes
checking for main in -lpcap... no
checking to make nse... no
Explicitly disabling static compilation
checking for dlopen in -ldl... yes
checking for a BSD-compatible install... /usr/bin/install -c
configure: creating ./config.status
config.status: creating Makefile
config.status: creating tcl/lib/ns-autoconf.tcl
config.status: creating indep-utils/webtrace-conv/ucb/Makefile
config.status: creating indep-utils/webtrace-conv/dec/Makefile
config.status: creating indep-utils/webtrace-conv/nlanr/Makefile
config.status: creating indep-utils/webtrace-conv/epa/Makefile
config.status: creating indep-utils/cmu-scen-gen/setdest/Makefile
config.status: creating autoconf.h
config.status: autoconf.h is unchanged
Post # 20
thanks for the reply..
yes i did use the sudo for the previouss build, with the command suggested by you in the previous post and shown in the code window i was able to run the ./config command, but when i run the third command i m getting the same error as in post#5
Code:
sudo chown -R najmaismat:najmaismat *
najmaismat@ubuntu:~/ns-allinone-2.29$ export CXX=g++-4.1 && ./configure
najmaismat@ubuntu:~/ns-allinone-2.29$ export CC=gcc-4.1 CXX=g++-4.1 && ./install
RAttribute*> > >*)':
accessPointDiffApp.cc:(.text._ZN24NRSimpleAttributeFactoryIP7AppDataE4findEPSt6vectorIP11NRAttributeSaIS5_EEPN9__gnu_cxx17__normal_iteratorIPS5_S7_EE[NRSimpleAttributeFactory<AppData*>::find(std::vector<NRAttribute*, std::allocator<NRAttribute*> >*, __gnu_cxx::__normal_iterator<NRAttribute**, std::vector<NRAttribute*, std::allocator<NRAttribute*> > >*)]+0x33): undefined reference to `NRAttribute::find_key_from(int, std::vector<NRAttribute*, std::allocator<NRAttribute*> >*, __gnu_cxx::__normal_iterator<NRAttribute**, std::vector<NRAttribute*, std::allocator<NRAttribute*> > >, __gnu_cxx::__normal_iterator<NRAttribute**, std::vector<NRAttribute*, std::allocator<NRAttribute*> > >*)'
mannasim/diffusion/accessPointDiffApp.o:(.rodata._ZTI18AccessPointDiffApp[typeinfo for AccessPointDiffApp]+0x18): undefined reference to `typeinfo for DiffApp'
collect2: ld returned 1 exit status
make: *** [ns] Error 1
Ns make failed!
Post # 22
I was running ns2 with mannasim perfectly on this machine for the last 1 year, and it was running a week ago. I made few changes in battery.cc and battery.h file run make and it compiled perfectly then I commented the changes I did and again run make I started encountering error, so that much I can tell you that mannasim works perfectly on 64-bit OS.
Regards,
Najma
Post # 23
hi,
do you think i need to install ns-2.29 mannasim from the scratch or it can be corrected.i really don't understand what happened with ns2 installation as i was running simulations on it from last one year and never experienced this.
please guide.
regards,
najma
Distribution: PCLinuxOS2023 Fedora38 + 50+ other Linux OS, for test only.
Posts: 17,511
Rep:
# 23, # 24.
First : You can have as may ns-allinone.2.29 as you want,
installed at the same time.
Suggest : Leave what you have, as it is, and experiment
with some new 'ns-allinone.2.29's in new directories.
About errors :
Things change, a minor update of a system package
can cause a certain compiler not to work with mannasim.
Nothing in your above posts indicates that you remember
what you did a year ago. ( Notes ? Backups ? ).
May be you have used g++-3.4 to compile the old old mannasim ?
Post #25
ok i m going to install ns-2.29 in another directory and will definitely let you know the result.
what i remember is that i had installed gcc 4.3 compiler to work with mannasim and is still have it in the backup. i've the complete backup folder of ns-2.29 mannasim. so please suggest should i use the backup ns-2.29 mannasim or should i installed it from the scratch. and also guide that in ~/.bashrc, do i need to change ns2 paths to the new one?
regards,
najma
Distribution: PCLinuxOS2023 Fedora38 + 50+ other Linux OS, for test only.
Posts: 17,511
Rep:
# 26 .
Quote:
and also guide that in ~/.bashrc
No entries are required to .bashrc .
That's just a 15 year old text from the days when students
used the University computer and had no access to a system PATH.
Your own computer : $ sudo cp ns /usr/local/bin/
( Or use 'sudo make install' which does the same.)
When you have more than one ns : Use different names.
Example : ns, ns-mannasim, ns229-mannasim, ns234-mannasim, etc.
Using : $ ns229-mannasim mannasim-rede-plana.tcl
Testing Ubuntu 10.04.3 - x86_64 with mannasim.
$ cd ns-allinone-2.29/ (It's ns-allinone-2.29.3 ).
$ patch -p1 < mannasim-patch.diff
$ export CC=gcc-4.1 CXX=g++-4.1 && ./install : No errors.
After an upgrade to "10.04.4" : Same result. No errors.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.