LinuxQuestions.org
Latest LQ Deal: Latest LQ Deals
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Ubuntu
User Name
Password
Ubuntu This forum is for the discussion of Ubuntu Linux.

Notices


Reply
  Search this Thread
Old 06-27-2013, 08:20 AM   #31
knudfl
LQ 5k Club
 
Registered: Jan 2008
Location: Copenhagen DK
Distribution: PCLinuxOS2023 Fedora38 + 50+ other Linux OS, for test only.
Posts: 17,517

Rep: Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641

# 30, @amayamoah.

Please install g++41-compat / g++41-compat, post #6 here ..
http://www.linuxquestions.org/questi...mand-916594/#6

And make sure that ns-allinone-2.29.3.tar.gz is used ..
http://sourceforge.net/projects/nsna...allinone-2.29/

$ cd ns-allinone-2.29/ && export CC=gcc41 CXX=g++41 && ./install

-
 
Old 06-28-2013, 07:50 AM   #32
amayamoah
LQ Newbie
 
Registered: Dec 2011
Posts: 5

Rep: Reputation: Disabled
problem installing ns-allinone-2.29.3 on ubuntu 10.10

Hello knudfl,
Thanks a lot for the reply.
I think the ns2.29.3 installation is working except that i am including the patch for clustering-2.29 for which i am getting errors; and this makes the ns-allinone-2.29.3 installation incomplete. I want to believe the error is due to the patch. Pls do u have any idea about this clustering patch? below is the error message:
clustering/rajaraman/definitions_raj.h:105: error: from definition of ‘bool std::less<_Tp>:perator()(const _Tp&, const _Tp&) const [with _Tp = _AlgorithmTime]’
make: *** [clustering/rajaraman/rajaraman.o] Error 1
Ns make failed!

below is the content of the definitions_raj.h file --- i have indicated where the line 105 is

Code:
typedef struct _AlgorithmTime {
	// Round.
	int				round;
	// Fase.
	int				fase;
	// Valore massimo di fase.
	int				last_fase;
	
	public:

		_AlgorithmTime() {
			round = 0;
			fase = 0;
			last_fase = 0;
		}
	
		// Costruttore.
		_AlgorithmTime(int r, int f, int l) {
			round = r;
			fase = f;
			last_fase = l;
		}

		// Costruttore.
		_AlgorithmTime(const _AlgorithmTime & t) {
			round = t.round;
			fase = t.fase;
			last_fase = t.last_fase;
		}
		
		// Operatore di uguaglianza.
		bool operator== (struct _AlgorithmTime & t) {
			return ((t.fase == fase) && (t.round == round));
		}

		// Operatore minore.
		bool operator < (struct _AlgorithmTime & t) {
			if (round < t.round)
				return true;
			if (round > t.round)
				return false;
			if (fase < t.fase)
				return true;
			return false;
		}

		// Operatore maggiore.
		bool operator > (struct _AlgorithmTime & t) {
			if (round > t.round)
				return true;
			if (round < t.round)
				return false;
			if (fase > t.fase)
				return true;
			return false;
		}
		
		void operator++ () {
			if (fase == last_fase) {
				round++;
				fase = 0;
				return;
			}
			fase++;
		}

		void operator-- () {
			if (fase == 0) {
				round--;
				fase = last_fase;
				return;
			}
			fase--;
		}
} AlgorithmTime;

bool
std::less<AlgorithmTime>::operator()(const AlgorithmTime & t1, const AlgorithmTime & t2) const
{ 
	if (t1.round < t2.round)
		return true;
	if (t1.round > t2.round)
		return false;
	if (t1.fase < t2.fase)
		return true;
	return false;
}

Last edited by amayamoah; 07-01-2013 at 08:19 AM.
 
Old 06-28-2013, 09:41 AM   #33
knudfl
LQ 5k Club
 
Registered: Jan 2008
Location: Copenhagen DK
Distribution: PCLinuxOS2023 Fedora38 + 50+ other Linux OS, for test only.
Posts: 17,517

Rep: Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641
# 32 .

Please hit the 'Edit' button, and delete the code in post #32.
And then reenter the real code to post #32 : In code tags ..
http://www.linuxquestions.org/questi...gs-4175464257/
I.e. type [/code] at code end, and [code] at code start.
Or use the # button in the 'Advanced Editor'.


"patch for clustering-2.29" : Is it this one .. ?
http://www.michele-mastrogiovanni.ne...ware/download/

-

Last edited by knudfl; 06-28-2013 at 05:52 PM.
 
1 members found this post helpful.
Old 07-01-2013, 08:26 AM   #34
amayamoah
LQ Newbie
 
Registered: Dec 2011
Posts: 5

Rep: Reputation: Disabled
problem installing ns-allinone-2.29.3 on ubuntu 10.10

Hi Knudfl,
Thanks a lot for the reply. I find the [/code] and [code] tags very useful. Really makes the post quite clear; differentiating questions and comments from real program codes. thanks a lot.

Yeah, it is the same link i got the clustering patch from:

http://www.michele-mastrogiovanni.ne...ware/download/

I followed the instructions provided in the read me and even the one from the link below:
http://translate.google.com/translat...d%3D126&anno=2


Pls do u have any idea about this clustering?

Last edited by amayamoah; 07-01-2013 at 08:28 AM.
 
Old 07-01-2013, 08:45 AM   #35
knudfl
LQ 5k Club
 
Registered: Jan 2008
Location: Copenhagen DK
Distribution: PCLinuxOS2023 Fedora38 + 50+ other Linux OS, for test only.
Posts: 17,517

Rep: Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641
# 34 : OK → http://www.michele-mastrogiovanni.ne...ware/download/

The code compiles OK here :
$ cd ns-allinone-2.29/
$ patch -p1 < clustering-2.29.patch
$ export CC=gcc-3.4 CXX=g++-3.4 && ./install
... i.e. the "clustering-2.29 code" is old, requires gcc/g++ version 3.4.6 .

? What's the output from the command $ uname -m <Enter>

-
 
Old 07-01-2013, 09:21 AM   #36
amayamoah
LQ Newbie
 
Registered: Dec 2011
Posts: 5

Rep: Reputation: Disabled
problem installing ns-allinone-2.29.3 on ubuntu 10.10

Hi Knudfl,

so should i install the g++-3.4.6?

the output from the command $ uname -m is
i686

I did just as you did and got the following message :
Code:
.gnu.linkonce.t._ZN11taskPending10taskStatusEh' referenced in section `.rodata' of wpan/p802_15_4mac.o: defined in discarded section `.gnu.linkonce.t._ZN11taskPending10taskStatusEh' of wpan/p802_15_4mac.o
collect2: ld returned 1 exit status
make: *** [ns] Error 1
Ns make failed!
I am working with ubuntu 10.10

Last edited by amayamoah; 07-01-2013 at 12:10 PM.
 
Old 07-01-2013, 01:38 PM   #37
knudfl
LQ 5k Club
 
Registered: Jan 2008
Location: Copenhagen DK
Distribution: PCLinuxOS2023 Fedora38 + 50+ other Linux OS, for test only.
Posts: 17,517

Rep: Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641
# 36 .

OK, the 32bits (i686) Ubuntu 10.10 : Right, g++34 is no good with some files.

$ cd ns-allinone-2.29/ns-2.29/
.. Then edit the Makefile, line 37 to : CXX = g++41

$ make clean && make
.. When the errors appear, edit the Makefile to : CXX = g++-3.4
( Or whatever the naming is for your g++ version 3.4 ).
And : $ make
.. Ends OK here, the executable 'ns' is created.

Binary package : clustering-ns-2.29-ubuntu10_i386.deb, 4.1 MB
https://docs.google.com/file/d/0B7S2...it?usp=sharing
.. provides /usr/local/bin/ns-clustering
Using : $ ns-clustering <example>.tcl -t <?> -<etc. etc. options>

-

Last edited by knudfl; 07-01-2013 at 01:42 PM.
 
  


Reply

Tags
bittorrent-p2p, clustering-2.29, ns2, p2p-ns2



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
PXE installation problem - can only select A series packages for installation Nylex Slackware 4 08-19-2010 02:15 PM
Installation of Binutils(configure:error:installation or configuration problem:C ...) h_r0019 Linux From Scratch 1 05-05-2007 07:40 AM
Redhat/Linux Installation Support??? Is It Red hat installation problem??? wanux Red Hat 1 08-01-2006 10:32 PM
LiLo Installation problem ?and (GNOME and KDE problem) hitesh_linux Linux - Software 1 01-01-2002 04:56 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Ubuntu

All times are GMT -5. The time now is 09:04 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
Open Source Consulting | Domain Registration