Skip to main content



      Home
Home » Eclipse Projects » Eclipse Platform » Ant build problem
Ant build problem [message #73137] Fri, 13 June 2003 03:46 Go to next message
Eclipse UserFriend
Hi,

I have a strange problem when using ant in combine with Eclipse. It seems
that eclipse dont change the time the file was changed (or something like
that). Anyway, when I edit a java file and then want to do a build, I run my
ant task. the problem is that it doesnt compile any files if there is an old
class file in the output directory. I know the build.xml works for "manual"
builds as I tested running it from a dos-promt and edit the java file in
another editor. I dont want to fix this through a "clean" task in the
build.xml so that is not an option. I guess there is something small I have
missed somewhere.

<target name="init">
<tstamp/>
</target

<target name="compile" depends="init">
<javac classpath = "${classpath}"
srcdir = "${src}"
destdir = "${build}"
deprecation = "on"
debug= "on"
>
<include name="**/*.java"/>
</javac>
</target>

Thanks in advance!
Re: Ant build problem [message #73156 is a reply to message #73137] Fri, 13 June 2003 04:06 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: hcs33.egon.gyaloglo.hu

Hi,

I think this is because you have Eclipse's auto compile on save option set.
In this case ant won't compile any source because the class files are always
up-to-date with the source.
To manage auto compile, see Window-->Preferences-->Workbench-->Perform build
automatically on resource modification.

HTH,
Regards,
Csaba

"Mathias" <mathias.ohlsson@enovation.se> wrote in message
news:bcbvfu$l5m$1@rogue.oti.com...
> Hi,
>
> I have a strange problem when using ant in combine with Eclipse. It seems
> that eclipse dont change the time the file was changed (or something like
> that). Anyway, when I edit a java file and then want to do a build, I run
my
> ant task. the problem is that it doesnt compile any files if there is an
old
> class file in the output directory. I know the build.xml works for
"manual"
> builds as I tested running it from a dos-promt and edit the java file in
> another editor. I dont want to fix this through a "clean" task in the
> build.xml so that is not an option. I guess there is something small I
have
> missed somewhere.
>
> <target name="init">
> <tstamp/>
> </target
>
> <target name="compile" depends="init">
> <javac classpath = "${classpath}"
> srcdir = "${src}"
> destdir = "${build}"
> deprecation = "on"
> debug= "on"
> >
> <include name="**/*.java"/>
> </javac>
> </target>
>
> Thanks in advance!
>
>
Re: Ant build problem [message #73188 is a reply to message #73156] Fri, 13 June 2003 04:16 Go to previous messageGo to next message
Eclipse UserFriend
Hi,

Thanks for the help. That solved my issue with the compiling. I just have a
follow-up question on this..:)
When I compile i only get this in the Console:

Buildfile: D:\Project\myproject\build.xml

init:

compile:

BUILD SUCCESSFUL
Total time: 411 milliseconds

Even though it really compiles some files. Im looking for the setting to set
so I see something like this:

compile:
[javac] Compiling 1 source file to D:\Project\myproject\lib

As one do in the dos-prompt.

Thanks again!

/Mathias Ohlsson


"Horv
Re: Ant build problem [message #73346 is a reply to message #73188] Fri, 13 June 2003 08:38 Go to previous message
Eclipse UserFriend
Originally posted by: darin_swanson.oti.com

Discussed in the eclipse.tools.jdt newsgroup where you cross-posted...please
don't do that.

Darins

"Mathias Ohlsson" <mathias.ohlsson@enovation.se> wrote in message
news:bcc18p$nco$1@rogue.oti.com...
> Hi,
>
> Thanks for the help. That solved my issue with the compiling. I just have
a
> follow-up question on this..:)
> When I compile i only get this in the Console:
>
> Buildfile: D:\Project\myproject\build.xml
>
> init:
>
> compile:
>
> BUILD SUCCESSFUL
> Total time: 411 milliseconds
>
> Even though it really compiles some files. Im looking for the setting to
set
> so I see something like this:
>
> compile:
> [javac] Compiling 1 source file to D:\Project\myproject\lib
>
> As one do in the dos-prompt.
>
> Thanks again!
>
> /Mathias Ohlsson
>
>
> "Horv
Previous Topic:Showing matching brace that is offscreen
Next Topic:proxy for update also for CVS?
Goto Forum:
  


Current Time: Sun Apr 27 14:28:51 EDT 2025

Powered by FUDForum. Page generated in 0.03593 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top