You are viewing a plain text version of this content. The canonical link for it is here.
Posted to log4cxx-user@logging.apache.org by Raymond Lau <rl...@valicore.com> on 2005/05/13 01:29:17 UTC

problem running a test programming on linux

I tried to run a test program on linux, but got the following error.

Does anyone have an idea what I might have forgotten to set up?

 

Thanks

 

---- config file used ------------------------------

log4j.rootLogger=debug, stdout

log4j.appender.stdout=org.apache.log4j.ConsoleAppender

log4j.appender.stdout.layout=org.apache.log4j.PatternLayout

# Pattern to output the caller's file name and line number.

log4j.appender.stdout.layout.ConversionPattern=%5p [%t] (%F:%L) - %m%n

----------------------------------------------------------------

Error

 

Could not instantiate class [org.apache.log4j.ConsoleAppender].

Class 'org.apache.log4j.ConsoleAppender' not found Could not instantiate
appender named "stdout".

No appenders could be found for logger (TestLogger).

Please initialize the log4cxx system properly.

________________________________

From: Raymond Lau [mailto:rlau@valicore.com] 
Sent: Wednesday, May 11, 2005 3:49 PM
To: log4cxx-user@logging.apache.org
Subject: build problem on cygwin running gcc version 3.3.3

 

When I tried to build log4cxx by just issuing a "make" command after
running configure,

 

I got the following compilation error:

 

../include/log4cxx/helpers/tchar.h:51: error: 'swprintf' undeclared
(first use this function)

 

Does that has to do with g++ and the std library?

 


Re: problem running a test programming on linux

Posted by Curt Arnold <ca...@houston.rr.com>.
I'm working through issues right now with static linking of log4cxx  
(current Windows and then Unix).  What you are likely seeing is that  
a static link has either not including the ConsoleAppender in the  
link, therefore it is not getting registered as an available class or  
the registration occurs after after the default initialization.   
Neither is fixable within the calling code.  If you can use the  
shared libraries for a few days, I should be able to get the static  
linking issues worked through.


On May 12, 2005, at 6:29 PM, Raymond Lau wrote:

> I tried to run a test program on linux, but got the following error.
>
> Does anyone have an idea what I might have forgotten to set up?
>
>
>
> Thanks
>
>