namespace ns3{NS_LOG_COMPONENT_DEFINE ("mynewcomponent");
[1797/1916] Compiling src/wifi/model/FilethatincludestheMynewcomponentheader.cc
In file included from ./ns3/my-new-component.h:33:0, from ../src/wifi/model/HeaderFilethatincludestheMynewcomponentheader.cc:32, from ../src/wifi/model/FilethatincludestheMynewcomponentheader.cc:25:./ns3/log.h:202:28: error: redefinition of ‘ns3::LogComponent ns3::g_log’ static ns3::LogComponent g_log = ns3::LogComponent (name, __FILE__) ^../src/wifi/model/FilethatincludestheMynewcomponentheader.cc:33:1: note: in expansion of macro ‘NS_LOG_COMPONENT_DEFINE’ NS_LOG_COMPONENT_DEFINE ("mynewcomponent"); ^./ns3/log.h:202:28: error: ‘ns3::LogComponent ns3::g_log’ previously declared here static ns3::LogComponent g_log = ns3::LogComponent (name, __FILE__) ^./ns3/essoa-ESSOARole.h:38:1: note: in expansion of macro ‘NS_LOG_COMPONENT_DEFINE’ NS_LOG_COMPONENT_DEFINE ("mynewcomponent");
NS_LOG_COMPONENT_DEFINE(foo1)
NS_LOG_COMPONENT_DEFINE(foo2)
You're invited to test it on your code. Please report any issues asap since it will be pushed very soon.
Peter