This is probably due to a bug in javac, where deprecations are not reported
on files when they are compiled at the same time. The bug should be fixed in
Java 1.4.2. The different developers probably have different java versions
on their path.

See http://developer.java.sun.com/developer/bugParade/bugs/4216683.html for
more details.

/Daniel Grenner

-----Original Message-----
From: Kevin Steppe [mailto:[EMAIL PROTECTED]
Sent: den 10 februari 2004 16:00
To: [EMAIL PROTECTED]
Subject: No deprecation warnings with javac


I am not getting deprecation warning in the "build" target but I do in 
the "build-test" target, yet they look the same to me.  There are 230 
classes under /src and 27 under /test.  Just to be sure, I've 
intentionally placed calls in both /src and /test to a deprecated 
method.  The deprecated method is under /src.  This has been duplicated 
by two developers, but a third is getting the warnings from "build".  
Any suggestions would be greatly appreciated.  The build.xml follows:

<?xml version="1.0"?>

<project default="build">

<description>Build file for MinorThird</description>

<property name="src" location="src"/>
<property name="testDir" location="test"/>
<property name="javadoc" location="javadoc"/>
<property name="classDir" location="class"/>
<property name="jarsDir" location="lib"/>
<property name="reportsDir" location="testReports"/>
<property name="testRootDir" location="testRoot"/>

<path id="classpath">
  <fileset dir="${jarsDir}">
    <include name="**/*.jar"/>
  </fileset>
  <pathelement path="${classDir}"/>
</path>

<target name="init">
  <tstamp/>
  <mkdir dir="${classDir}"/>
</target>

<target name="clean" description="clean up">
  <delete dir="${classDir}"/>
  <delete dir="${reportsDir}"/>
  <delete dir="${testRootDir}"/>
</target>

<target name="build" depends="init"
  description="build the source ">
  <!-- Compile the java code from ${src} into ${classDir} -->
  <javac srcdir="${src}" destdir="${classDir}" debug="on" 
classpathref="classpath" deprecation="on"/>
</target>

<target name="build-test" depends="init, build">
  <javac srcdir="${testDir}" destdir="${classDir}" debug="on" 
classpathref="classpath" deprecation="on"/>
</target>

</project>



Thanks,
Kevin



---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to