ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Marc Klein" <Marc.Kl...@ids-scheer.de>
Subject Antw: RE: log4j question...
Date Fri, 12 Mar 2004 15:51:10 GMT
I had the same problem and using ANT_OPTS solved it:

set ANT_OPTS=-Dlog4j.configuration=file:.\log4j.properties
ant -listener org.apache.tools.ant.listener.Log4jListener

Bye

Marc


>>> ECiramella@emptoris.com 12.03.04 16:40:56 >>>
Ok, so in the case I'm using Cygwin (but not all developers are) how do I
reference this property file?

$ ant -listener org.apache.tools.ant.listener.Log4jListener
-Dlog4j.configuration=file:///cygdrive/c/ant-testing/lib/log4j.properties
does not work neither does:
$ ant -listener org.apache.tools.ant.listener.Log4jListener
-Dlog4j.configuration=file:////cygdrive/c/ant-testing/lib/log4j.properties

And if absolute is the case, I stil can't get it to find this property file
when it's in the current working directory, so:

$ ant -listener org.apache.tools.ant.listener.Log4jListener
-Dlog4j.configuration=file:///log4j.properties

-----Original Message-----
From: Peter Reilly [mailto:peter.reilly@corvil.com] 
Sent: Friday, March 12, 2004 10:37 AM
To: Ant Users List
Subject: Re: log4j question...


The file:/// format is absolute:
so you need to do something like:
file:///home/preilly/work/log4j.properties

Peter
Ciramella, EJ wrote:

>Yeah, this doesn't seem to work either - 
>
>  
>
>>file:/// URL as a value for the -Dlog4j.configuration
>>    
>>
>
>I tried:
>$ ant -listener org.apache.tools.ant.listener.Log4jListener
>-Dlog4j.configuration=file:///../apache-ant-1.5.4/lib/log4j.properties
>
>No success, so then I moved the properties file locally:
>$ ant -listener org.apache.tools.ant.listener.Log4jListener
>-Dlog4j.configuration=file:///log4j.properties
>
>No success, I still get the following two errors:
>
>Buildfile: build.xml
>log4j:WARN No appenders could be found for logger (org.apache.tools.ant).
>log4j:WARN Please initialize the log4j system properly.
>
>
>Again, if the SAME property file is in a jar in the ANT_HOME/lib dir,
things
>work fine.
>
>  
>


---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@ant.apache.org 
For additional commands, e-mail: user-help@ant.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@ant.apache.org
For additional commands, e-mail: user-help@ant.apache.org


Mime
View raw message