Bug 19224

Summary: The <javac> task should accept the 'dependcache' and 'dependcacheref' attributes
Product: Ant Reporter: Christophe FOUQUE <cfouque>
Component: Core tasksAssignee: Ant Notifications List <notifications>
Status: NEW ---    
Severity: enhancement    
Priority: P3    
Version: 1.7.0   
Target Milestone: ---   
Hardware: All   
OS: All   
Attachments: animation of baseline-shift property
scripting of the baseline-shift property

Description Christophe FOUQUE 2003-04-22 19:11:00 UTC
We use 'WorkAreas' pointing to 'Baselines' (see bug 19006).


Currently, the <depend> task works by deleting all outdated 'class' files from 
'srcdir'.

But the 'Baselines' are read-only (once published, their content must never be 
modified), so the <depend> task can NOT handle Java dependencies for 'WorkAreas' 
pointing to 'Baselines'.


My enhancement request is that the <javac> task accepts the 'dependcache' and 
'dependcacheref' attributes (similar respectively to the 'sourcepath' and 
'sourcepathref' attributes) :

If 'dependcache' or 'dependcacheref' is specified :

-  If <javac> does NOT find the dependencies cache in the first directory of 
'dependcache', then it should copy it from the next directory of 'dependcache'.

-  Whenever a first 'java' file in 'srcdir' has an absent or outdated 
corresponding 'class' file in 'classpath', then <javac> should also recompile 
all 'java' files in 'sourcepath' impacted by this first 'java' file.


Then the following statements should work :

    <path  id="myPath">
      <pathelement  location="${basedir}"/>
      <pathelement  location="${sp1}"/>
      <pathelement  location="${sp2}"/>
    </path>       

    <javac      srcdir="${basedir}"
               destdir="${basedir}"
         sourcepathref="myPath"
          classpathref="myPath"
        dependcacheref="myPath"/>


I know very well that the implementation of this feature is a lot of work for 
you (I have implemented it in the PERL script that we use everyday), but this 
feature is mandatory for us to replace our proprietary PERL script by 
'build.xml' files.
Comment 1 Nicolas Socheleau 2009-06-16 09:05:54 UTC
Created attachment 23812 [details]
animation of baseline-shift property

testcase for the animation of the baseline-shift property using <animate/> and <set/>
Comment 2 Nicolas Socheleau 2009-06-16 09:06:49 UTC
Created attachment 23813 [details]
scripting of the baseline-shift property

testrcase with onload ecmascript that modifies the baseline-shift property
Comment 3 Nicolas Socheleau 2009-06-16 09:11:31 UTC
please disregard the attached files
Thanks.