Yes, sorry, that's what I meant.

On Thu, Dec 06, 2012 at 01:24:43AM +0500, Ahmed Talha Khan wrote:
> What exactly do you mean by that? Do you want me to past config.log?
> 
> 
> On Thu, Dec 6, 2012 at 12:50 AM, Ben Pfaff <b...@nicira.com> wrote:
> 
> > What's in config.status?
> >
> > On Wed, Dec 05, 2012 at 11:46:17PM +0500, Ahmed Talha Khan wrote:
> > > Its Linux with kernel 2.6.35 on Fedora 14 x86_64 machine. And yes thats
> > > what I though too that only VLOG_DEFINE_THIS_MODULE should do the job as
> > it
> > > creates and the actual module as well as the reference.
> > >
> > > I see that it is defined like this
> > >
> > > #define VLOG_DEFINE_THIS_MODULE(MODULE)                                 \
> > >         VLOG_DEFINE_MODULE(MODULE);                                     \
> > >         static struct vlog_module *const THIS_MODULE = &VLM_##MODULE
> > >
> > >
> > > The 2nd line to create a reference works as its not a compile issue. The
> > > linker cries which means that VLOG_DEFINE_MODULE(MODULE) failed to create
> > > the module in the linker section as given by
> > >
> > > #define VLOG_DEFINE_MODULE(MODULE)                                      \
> > >         VLOG_DEFINE_MODULE__(MODULE)                                    \
> > >         extern struct vlog_module *vlog_module_ptr_##MODULE;            \
> > >         struct vlog_module *vlog_module_ptr_##MODULE                    \
> > >             __attribute__((section("vlog_modules"))) = &VLM_##MODULE
> > >
> > >
> > > Any ideas now what might have happened? Could be it some sort of a
> > version
> > > mis-match for the GNU linker "ld"?
> > >
> > >
> > >
> > > On Wed, Dec 5, 2012 at 8:35 PM, Ben Pfaff <b...@nicira.com> wrote:
> > >
> > > > On Wed, Dec 05, 2012 at 12:29:51PM +0500, Ahmed Talha Khan wrote:
> > > > > I am trying to register one of my own modules for logging purpose
> > but it
> > > > > does not seem to work.
> > > > >
> > > > > In my source file xyz.c included
> > > > >
> > > > > VLOG_DEFINE_THIS_MODULE(xyz);
> > > > >
> > > > > and then later in the file i use
> > > > >
> > > > > VLOG_INFO("some msg printed here")
> > > > >
> > > > > But when I run make, the linker cries:
> > > > >
> > > > > undefined reference to `VLM_xyz'.
> > > > >
> > > > > What am I missing here. Isnt this suppose to be a simple operation?
> > > >
> > > > Yes, all you should need is the VLOG_DEFINE_THIS_MODULE line.
> > > >
> > > > What kind of system are you using?
> > > >
> > >
> > >
> > >
> > > --
> > > Regards,
> > > -Ahmed Talha Khan
> >
> 
> 
> 
> -- 
> Regards,
> -Ahmed Talha Khan
_______________________________________________
discuss mailing list
discuss@openvswitch.org
http://openvswitch.org/mailman/listinfo/discuss

Reply via email to