Bug 142 - ns-3.0.11 fails to build with gcc 3.4
: ns-3.0.11 fails to build with gcc 3.4
Status: RESOLVED FIXED
: ns-3
simulation core
: pre-release
: All All
: P3 normal
Assigned To:
:
:
:
:
  Show dependency treegraph
 
Reported: 2008-02-18 12:31 EDT by
Modified: 2008-07-01 13:32 EDT (History)


Attachments


Note

You need to log in before you can comment on or make changes to this bug.


Description From 2008-02-18 12:31:57 EDT
C:\Documents and Settings\gjc\ns-3.0.11>waf
Entering directory `C:\DOCUME~1\gjc\ns-3.0.11/build'
[138/410] * cpp : src\core\object.cc -> build\debug\src\core\object.os
In file included from ..\src\core\object.cc:21:
..\src\core\object.h:297: error: got 1 template parameters for `ns3::TypeId
ns3:
:TypeId::AddConstructor()'
..\src\core\object.h:297: error:   but 6 required
..\src\core\object.h:310: error: redefinition of `ns3::TypeId
ns3::TypeId::AddCo
nstructor()'
..\src\core\object.h:297: error: `ns3::TypeId ns3::TypeId::AddConstructor()'
pre
viously declared here
..\src\core\object.h:310: error: got 2 template parameters for `ns3::TypeId
ns3:
:TypeId::AddConstructor()'
..\src\core\object.h:310: error:   but 6 required
..\src\core\object.h:323: error: redefinition of `ns3::TypeId
ns3::TypeId::AddCo
nstructor()'
..\src\core\object.h:297: error: `ns3::TypeId ns3::TypeId::AddConstructor()'
pre
viously declared here
..\src\core\object.h:323: error: got 3 template parameters for `ns3::TypeId
ns3:
:TypeId::AddConstructor()'
..\src\core\object.h:323: error:   but 6 required
..\src\core\object.h:336: error: redefinition of `ns3::TypeId
ns3::TypeId::AddCo
nstructor()'
..\src\core\object.h:297: error: `ns3::TypeId ns3::TypeId::AddConstructor()'
pre
viously declared here
..\src\core\object.h:336: error: got 4 template parameters for `ns3::TypeId
ns3:
:TypeId::AddConstructor()'
..\src\core\object.h:336: error:   but 6 required
..\src\core\object.h:349: error: redefinition of `ns3::TypeId
ns3::TypeId::AddCo
nstructor()'
..\src\core\object.h:297: error: `ns3::TypeId ns3::TypeId::AddConstructor()'
pre
viously declared here
..\src\core\object.h:349: error: got 5 template parameters for `ns3::TypeId
ns3:
:TypeId::AddConstructor()'
..\src\core\object.h:349: error:   but 6 required
..\src\core\object.h:362: error: redefinition of `ns3::TypeId
ns3::TypeId::AddCo
nstructor()'
..\src\core\object.h:297: error: `ns3::TypeId ns3::TypeId::AddConstructor()'
pre
viously declared here
Build failed
 -> task failed (err #129): [<b:C:\DOCUME~1\gjc\ns-3.0.11\src\core\object.os>]

g++ version is 3.4.5 (current mingw).
------- Comment #1 From 2008-02-18 12:34:03 EDT -------
CXX=/usr/bin/g++-3.4 ./waf configure && ./waf build

Was able to reproduce in Linux, with g++ 3.4.  Same error.  Is g++ 3.4
officially supported by NS-3?
------- Comment #2 From 2008-02-18 12:38:06 EDT -------
PS: if gcc 3.4 is officially supported, is there any chance of adding a gcc 3.4
build to the build bots?... ;-)
------- Comment #3 From 2008-02-18 12:45:06 EDT -------
Yes, I showed this to Mathieu a week or two ago; apparently not a trivial fix. 
Sorry for not filing a bug.

yes, we can add gcc-3.4 to the build bots once this is fixed.
------- Comment #4 From 2008-02-18 12:53:29 EDT -------
But maybe adding a gcc-3.4 build bot sooner rather than later will "encourage"
Mathieu to fix it?... just an idea... :-)
------- Comment #5 From 2008-02-27 00:38:04 EDT -------
*** Bug 128 has been marked as a duplicate of this bug. ***
------- Comment #6 From 2008-03-14 13:09:39 EDT -------
Bug fixed on ns-3-param branch to be merged soon.

tested on ubuntu 7.10 64 bit g++ 3.4