ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From RLancas...@dynamiccontrols.com
Subject Re: Detecting modified times and exiting a target
Date Mon, 28 Jul 2008 21:51:56 GMT
Not what you were asking for - but:

Use cpptask from the ant-contrib project - this handles all the logic of 
compiling C and CPP, and also has some plugins for fortran. If handles all 
the dependancy analysis for the Code and if your using a standard compiler 
gcc, msvc it's all done for you.... all you have to do is configure it ;-)




André Pilz <andre.pilz@pcvisit.de> 
28/07/2008 09:08 p.m.
Please respond to
"Ant Users List" <user@ant.apache.org>


To
Ant Users List <user@ant.apache.org>
cc

Subject
Re: Detecting modified times and exiting a target






Already tested the <uptodate> task?

Shug Boabby schrieb:
> Hi all,
> 
> I am utterly failing at attempting to implement some logic in an ant
> script, I was hoping somebody here could help.
> 
> I have a target which calls an external (non-standard) compiler. The
> compiler takes a directory as a parameter and recursively compiles
> everything inside that folder to an output folder, but it is not smart
> enough to know when it is not necessary to do the compilation. (i.e. 2
> calls to the target will result in the compilation step being started
> from scratch each time, despite the source folder not changing).
> 
> In this target, I need to implement the following logic:-
> 
> - get the latest modified time of the source folder (looking
> recursively at all files)
> - get the latest modified time of the output folder (looking
> recursively at all files)
> - if the output folder has been modified since the source folder, then
> exit the task
> 
> Could somebody please help me implement this in ant-speak?
> 
> ---------------------------------------------------------------------
> 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



_______________________________________________________________________

This email and any files transmitted with it are confidential and
intended solely for the use of the individual or entity to whom they
are addressed. If you have received this email in error please notify
the sender of this email.
_______________________________________________________________________

This e-mail message has been scanned and cleared by MailMarshal at
www.dynamiccontrols.com

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message