ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Antoine Levy-Lambert <anto...@gmx.de>
Subject Re: Question regarding -Xlint:unchecked
Date Sat, 16 Dec 2006 05:44:24 GMT
Hello Chun Ji,

please check the path that you pass in the dir attribute of the <ant/ 
 > invocation. Probably, it should be <ant dir="."/> and not <ant  
dir="${src.dir}" . You want this attribute to be the basedirectory of  
the build file that you invoke.
Regards,

Antoine
On Dec 15, 2006, at 2:54 PM, Chun Ji wrote:

>
>
> I have two build.xml used for my daily work. The first one has only  
> one target, which is to compile the source code. For the second  
> build.xml, there are a list of "targets", including a "target",  
> that is to invoke the "compiling" target in the first build.xml.  
> Here is part the my build.xml files look like:
>
> First build.xml
>      ...
>      <target name="compile" depends="init">
>         <javac srcdir="${src.dir}" destdir="${build.dir}">
>             <classpath refid="compile.classpath"/>
>                         <compilerarg value="-Xlint:unchecked"/>
>         </javac>
>     </target>
>     ...
>
> Second build.xml
>     ...
>     <target name="call-build" ...>
>       <ant antfile="build.xml" dir="${src.dir}" inheritAll="false"  
> target="compile">
>         <property name="p4root" value="/home/cji/sfo/abc"/>
>      </ant>
>    </target>
>    ...
>
> So during the compiling time, when I run "ant call-build" by the  
> second build.xml, it will invoke the real compiling action in the  
> first one and do the build.
>
> But what I have found is if I am doing it this way, the setting  
> "<compilerarg value="-Xlint:unchecked"/>" does not take any effect,  
> I still see a lots of warnings in the compiling log file, while if  
> I call "ant compile" by the first build.xml, I get a "clean" build.
>
> Does someone know why ?
>
>
> thanks,
>
>
> chun Ji
>


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


Mime
View raw message