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 Torsten Wiebesiek <to...@grecon.de> on 2007/11/16 10:53:38 UTC

Unittests fail

Hello,

I (once again) have problems compiling log4cxx on my Windows-System. :-(

The unit tests fail. I don't really know, since when this occurs but
it's
at least 3 days now. I have attached the last lines of the ant build.

I tried to compile log4cxx with `ant -Ddebug=false -Dlib.type=static`.

Is this again a problem of my system configuration, which I haven't
changed
(hopefully), or is it a known problem?

Thanks for you help,

  Torsten


>     [exec] log4cxx: Parsing layout options for "A".
>     [exec] log4cxx: Setting option name=[ConversionPattern], value=[%p
%c = %m%n]
>     [exec] log4cxx: End of parsing for "A".
>     [exec] log4cxx: Setting option name=[Append], value=[false]
>     [exec] log4cxx: Setting option name=[File], value=[output/temp]
>     [exec] log4cxx: Parsed "A" options.
>     [exec] log4cxx: Finished configuring.
>     [exec] .log4cxx: DOMConfigurator configuring file
input/xml/customLogger1.xml...
>     [exec] log4cxx: debug attribute= "false".
>     [exec] ..................................log4cxx: Empty conversion
specifier
>     [exec] .log4cxx: Empty conversion specifier
>     [exec] 2007-11-16 10:37:36,048 DEBUG
org.apache.log4j.rolling.SizeBasedRollingTest -Hello---0
>     [exec] 2007-11-16 10:37:36,048 DEBUG
org.apache.log4j.rolling.SizeBasedRollingTest -Hello---1
>     [exec] 2007-11-16 10:37:36,048 DEBUG
org.apache.log4j.rolling.SizeBasedRollingTest -Hello---2
>     [exec] 2007-11-16 10:37:36,048 DEBUG
org.apache.log4j.rolling.SizeBasedRollingTest -Hello---3
>     [exec] 2007-11-16 10:37:36,048 DEBUG
org.apache.log4j.rolling.SizeBasedRollingTest -Hello---4
>     [exec] 2007-11-16 10:37:36,048 DEBUG
org.apache.log4j.rolling.SizeBasedRollingTest -Hello---5
>     [exec] 2007-11-16 10:37:36,048 DEBUG
org.apache.log4j.rolling.SizeBasedRollingTest -Hello---6
>     [exec] 2007-11-16 10:37:36,048 DEBUG
org.apache.log4j.rolling.SizeBasedRollingTest -Hello---7
>     [exec] 2007-11-16 10:37:36,048 DEBUG
org.apache.log4j.rolling.SizeBasedRollingTest -Hello---8
>     [exec] 2007-11-16 10:37:36,048 DEBUG
org.apache.log4j.rolling.SizeBasedRollingTest -Hello---9
[snip] (115 similar lines left out)
>     [exec] 2007-11-16 10:37:36,236 DEBUG
org.apache.log4j.rolling.SizeBasedRollingTest -Hello---0
>     [exec] 2007-11-16 10:37:36,236 DEBUG
org.apache.log4j.rolling.SizeBasedRollingTest -Hello---1
>     [exec] 2007-11-16 10:37:36,236 DEBUG
org.apache.log4j.rolling.SizeBasedRollingTest -Hello---2
>     [exec] 2007-11-16 10:37:36,236 DEBUG
org.apache.log4j.rolling.SizeBasedRollingTest -Hello---3
>     [exec] 2007-11-16 10:37:36,236 DEBUG
org.apache.log4j.rolling.SizeBasedRollingTest -Hello---4
>     [exec] 2007-11-16 10:37:36,236 DEBUG
org.apache.log4j.rolling.SizeBasedRollingTest -Hello---5
>     [exec] 2007-11-16 10:37:36,236 DEBUG
org.apache.log4j.rolling.SizeBasedRollingTest -Hello---6
>     [exec] 2007-11-16 10:37:36,236 DEBUG
org.apache.log4j.rolling.SizeBasedRollingTest -Hello---7
>     [exec] 2007-11-16 10:37:36,236 DEBUG
org.apache.log4j.rolling.SizeBasedRollingTest -Hello---8
>     [exec] 2007-11-16 10:37:36,236 DEBUG
org.apache.log4j.rolling.SizeBasedRollingTest -Hello---9
>     [exec] 2007-11-16 10:37:36,236 DEBUG
org.apache.log4j.rolling.SizeBasedRollingTest -Hello--10
>     [exec] ..................log4cxx: Exception during rollover
>
> BUILD FAILED
> C:\Project\log4cxx\build.xml:1030: exec returned: -1073741819

Re: Unittests fail

Posted by Andreas Grob <an...@bergauer.ch>.
Curt Arnold <carnold <at> apache.org> writes:

> 
> 
> On Nov 16, 2007, at 10:33 AM, Andrew n marshall wrote:
> 
> > A coworker and I found the unittests depend on Unix tools like sed  
> > and awk.  They would fail on windows if you don't have something  
> > like Cygwin in the path.  I'm not sure if this is your problem, but  
> > it worth checking if it still fails with the Unix tools available.
> >
> >
> > Anm
> >
> 
> The unit tests require sed, gzip and zip on the path.  sed is used to  
> normalize log files by replacing dates, thread names and such before  
> comparison with "witness" files.    gzip and zip are used to compress  
> rolled over files when the file extension ends with ".gz" or ".zip"  
> which was recently implemented and perhaps was not added to the  
> INSTALL notes.  At the place that your tests are failing, it would  
> seem that missing gzip or zip is missing.
> 
> 

Hi,
I think, I have the same error. I tried svn r596563. (My last known revision
without that error was 566509 (the one I used so far)).

I'm using VS2005/SP1
ant -Ddebug=true -Doptimize=size

..........
[exec] 2007-11-20 09:52:41,476 DEBUG
org.apache.log4j.rolling.SizeBasedRollingTest -Hello--10
[exec] ...............log4cxx: Exception during rollover

Now starting the debugger:
Call Stack entry:
>	log4cxxd.dll!log4cxx::WriterAppender::subAppend(const
log4cxx::helpers::ObjectPtrT<log4cxx::spi::LoggingEvent> & event={...},
log4cxx::helpers::Pool & p={...})  Line 211 + 0x1b bytes	C++

Code:
void WriterAppender::subAppend(const spi::LoggingEventPtr& event, Pool& p)
{
        LogString msg;
        layout->format(msg, event, p);
        {
           synchronized sync(mutex);
*NEXT*           writer->write(msg, p);
           if (immediateFlush) {
	        writer->flush(p);
           }
        }
}

Cheers,
~ Andreas



Re: Unittests fail

Posted by Curt Arnold <ca...@apache.org>.
On Nov 16, 2007, at 10:33 AM, Andrew n marshall wrote:

> A coworker and I found the unittests depend on Unix tools like sed  
> and awk.  They would fail on windows if you don't have something  
> like Cygwin in the path.  I'm not sure if this is your problem, but  
> it worth checking if it still fails with the Unix tools available.
>
>
> Anm
>

The unit tests require sed, gzip and zip on the path.  sed is used to  
normalize log files by replacing dates, thread names and such before  
comparison with "witness" files.    gzip and zip are used to compress  
rolled over files when the file extension ends with ".gz" or ".zip"  
which was recently implemented and perhaps was not added to the  
INSTALL notes.  At the place that your tests are failing, it would  
seem that missing gzip or zip is missing.