fixunix
Tags Register FAQ Members List Social Groups Calendar Search Today's Posts Mark Forums Read

Undefined symbol 'logMsg'. help! - VxWorks

This is a discussion on Undefined symbol 'logMsg'. help! - VxWorks ; Hi guys, I've been trying to use the function logMsg defined in the logLib for our real time processing project. The complier always complaines this: dld: warning: Undefined symbol 'logMsg' in file 'PPC32diab_RTP_DEBUG/main.o' dld: error: Undefined symbols found - no ...


Fix Unix > Other OS > VxWorks > Undefined symbol 'logMsg'. help!

Reply
 
LinkBack Tools
  #1  
Old 10-02-2007, 08:30 AM
Junior Member
 
Join Date: Sep 2009
Posts: 0
Default Undefined symbol 'logMsg'. help!

Hi guys,

I've been trying to use the function logMsg defined in the logLib for
our real time processing project. The complier always complaines this:

dld: warning: Undefined symbol 'logMsg' in file
'PPC32diab_RTP_DEBUG/main.o'
dld: error: Undefined symbols found - no output written

The main.c was created in a RTP project with #include
defined. Why can't I use the function logMsg in my RTP application?
When I compile file main.c, the compiler has no error, but when I build
the RTP project, the complier complains!!! I looked at the source code
of logLib.c, logMsg requires msgQLib.h as well, which I also included.
still got error. I can't use printf() because I have some ISR
involved.

Please help!!
Thanks

Ray

Reply With Quote
  #2  
Old 10-02-2007, 08:30 AM
Junior Member
 
Join Date: Sep 2009
Posts: 0
Default Re: Undefined symbol 'logMsg'. help!

By the way, I am using Workbench 2.4, VxWorks 6.2. I had the same
problem when I used Workbench 2.3, VxWorks 6.1. This has nothing to do
with VxWorks I think, I can use logMsg() function in the kernel shell.
it's just that the compiler can't find the symbol while building the
RTP project.

Reply With Quote
  #3  
Old 10-02-2007, 08:31 AM
Junior Member
 
Join Date: Sep 2009
Posts: 0
Default Re: Undefined symbol 'logMsg'. help!

Ray:

logMsg should be defined when you load the .o under vxWorks. Sounds
like you are missing a loader option that allows the link to procede
with undefineds. All the vxWorks kernel and BSP calls are linked on
the target, not on the host.


Larry

Reply With Quote
  #4  
Old 10-02-2007, 08:31 AM
Junior Member
 
Join Date: Sep 2009
Posts: 0
Default Re: Undefined symbol 'logMsg'. help!

Ray:

logMsg should be defined when you load the .o under vxWorks. Sounds
like you are missing a loader option that allows the link to procede
with undefineds. All the vxWorks kernel and BSP calls are linked on
the target, not on the host.


Larry

Reply With Quote
  #5  
Old 10-02-2007, 08:31 AM
Junior Member
 
Join Date: Sep 2009
Posts: 0
Default Re: Undefined symbol 'logMsg'. help!

The above replies are correct, the linking is dynamic when you load
your module. (which is different that compiling).
When you compile (and link) on VxWorks there are all kinds of undefined
symbols in your .out then when you load the module the OS will perform
dynamic linking to link all the undefines to symbols that exist in the
OS.

This message is telling you that when it dynamically links it can't
find some symbols - this means that either another module that your
module depends on isn't loaded, you didn't statically link (i.e.
compile )in some code in your module that the module needs or the OS is
missing some components that your module uses. (in your case it's the
later)

You need to add the logLib (or something like that) component to your
OS. Just add the highest level component that your missing (i.e.
logLib, not msgQLib) and Tornado will take care of the other components
that are also needed.

Good Luck,
George

Reply With Quote
  #6  
Old 10-02-2007, 08:32 AM
Junior Member
 
Join Date: Sep 2009
Posts: 0
Default Re: Undefined symbol 'logMsg'. help!

Thanks for your comments guys. The problem still occurs though. We are
not using a Downloadable Kernel Module Project. We are actually having
this problem with Real-time Processing Project (no .out file built.
only vxe and .o files built). There is no problem with all default
setting using the DKM project. but once we used logMsg in the RTP
project, the linker just can't link to the source code of it. We then
tried manual specification on the RTP build proporties to link to the
library we want, but still failed. sigh...fraustrating~~

Reply With Quote
  #7  
Old 05-20-2009, 04:49 PM
Junior Member
 
Join Date: May 2009
Posts: 1
Default Re: Undefined symbol 'logMsg'. help!

From the logLib documentation:

CONFIGURATION
To use the message logging library, configure VxWorks with the INCLUDE_LOGGING component.

Basically, you have to turn it on. If you don't turn it on, you can't use it. How do you turn it on? I don't know, I asked my OS guy, and he did it for me. But it is part of the VxWorks image build process. So you have to rebuild your boot image with INCLUDE_LOGGING to be able to use logLib
Reply With Quote
  #8  
Old 02-07-2010, 04:39 AM
Junior Member
 
Join Date: Feb 2010
Posts: 1
Default Re: Undefined symbol 'logMsg'. help!

Unfortunately, logMsg() function is only available for kernel level projects. You can not use this function in RTP projects.
Reply With Quote
Reply

Tools


Similar Threads
Thread Thread Starter Forum Replies Last Post
Stumped - symbol loockup error: undefined symbol: EVP_idea_cbc unix Mandriva 24 01-14-2008 02:11 AM
Re: undefined symbol: RSA_generate_key unix modssl 0 10-07-2007 10:21 PM
Re: undefined symbol: RSA_generate_key unix modssl 0 10-07-2007 10:21 PM
Re: undefined symbol: RSA_generate_key unix modssl 0 10-07-2007 10:21 PM
ld : Undefined symbol unix Aix 1 10-04-2007 12:59 AM


All times are GMT. The time now is 10:38 AM.