The code can be made conditional so it will only execute on 1.2+ systems.
There are different solutions, the following is one of them:

   boolean jdk12;
   try {
      Class.forName("java.lang.Comparable");
      jdk12 = true;
   } catch (ClassNotFoundException e) {
      jdk12 = false;
   }

   if (jdk12) {
      destFile.setLastModified(sourceFile.lastModified());
   }

I suggest the JDK 1.2+ checking is done in a central place, like Project.


Ernst

Matthew Kuperus Heun wrote:
> Greetings:
> 
> >I solved this by adding the following code to Project.java on line 656:
> >
> >destFile.setLastModified(sourceFile.lastModified());
> >
> >I'm affraid this isn't Java 1.1 compatible, is this a problem?
> 
> Yes, for those of us on a Macintosh who don't have access to jdk1.2 
> yet.  (Will have it when OSX hits the streets.)  What is the general 
> policy for ANT wrt jdk1.2?
> 
> Cheers,
> 
> Matt
> -- 
> 
> 
> --
> 
> Matthew Kuperus Heun
> Global Aerospace Corporation
> +1 (978) 922-7115 (voice & fax)
> <http://www.gaerospace.com>
> <mailto:[EMAIL PROTECTED]>
> 

Reply via email to