Skip to main content



      Home
Home » Language IDEs » C / C++ IDE (CDT) » Using integrated debugger on Ant managed build
Using integrated debugger on Ant managed build [message #104709] Fri, 04 June 2004 10:19 Go to next message
Eclipse UserFriend
Originally posted by: bobk.asg.com

This is a multi-part message in MIME format.

------=_NextPart_000_0030_01C44A1D.66ABAB10
Content-Type: text/plain;
charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable

Thanks ahead if you can help: I want to use Ant to build my whole =
project (java & C++). To=20

prototype the c++ side I've created a 'hello' app and have created a =
build.xml for it. I debugged

it all outside of eclipse and then in eclipse was able to right click on =
the build.xml file and select

'Run Ant'. This, after a good delay, brought up a dialog that let me =
select the target and ran it.=20

Output from console is at bottom of this message. Great. =20

But now when I try to run the created binary in debugger, via a run =
configuration, I can not get

it to find the binary. In the Debug view, the "creat, manage and run =
configurations' panel gives

me a message "Program does not exist" message. Can't find a way to =
force it to look in that directory

and find the binary... Suspecting this is related to having to "make" =
the project before the debugger=20

can "see" it, I've tried to create a make target with Ant as the "build =
command" but I only get the below

message. Is there a way to drive the build with ant AND have the debug =
tool find it?

C-Build output:

Error launching builder (D:/ANT/apache-ant-1.6.1beta1/bin/ant all )

(Exec error:Launching failed)



Console output:

Buildfile: D:\eclipse\workspace\test\build.xml

help:

[echo] NMS test build file for Ant

[echo] The following targets are defined:

[echo] all - Compiles all .cpp files

all:

BUILD SUCCESSFUL

Total time: 281 milliseconds

------=_NextPart_000_0030_01C44A1D.66ABAB10
Content-Type: text/html;
charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META http-equiv=3DContent-Type content=3D"text/html; =
charset=3Diso-8859-1">
<META content=3D"MSHTML 6.00.2800.1400" name=3DGENERATOR>
<STYLE></STYLE>
</HEAD>
<BODY>
<DIV>
<P><FONT face=3DArial size=3D2>Thanks ahead if you can help:&nbsp; I =
want to use Ant=20
to build my whole project (java &amp; C++).&nbsp; To&nbsp;</FONT></P>
<P><FONT face=3DArial size=3D2>prototype the c++ side&nbsp;&nbsp;I've =
created a=20
'hello' app and have created a build.xml for it.&nbsp; I =
debugged</FONT></P>
<P><FONT face=3DArial size=3D2>it all outside of eclipse and then in =
eclipse was=20
able to right click on the build.xml file and select</FONT></P>
<P><FONT face=3DArial size=3D2>'Run Ant'.&nbsp; This, after a good =
delay, brought up=20
a dialog that let me select the target and ran it. </FONT></P>
<P><FONT face=3DArial size=3D2>Output from console is at bottom of this=20
message.&nbsp; Great.&nbsp; </FONT></P>
<P><FONT face=3DArial size=3D2>But now when I try to run the created =
binary in=20
debugger, via a run configuration, I can not get</FONT></P>
<P><FONT face=3DArial size=3D2>it to find the binary.&nbsp; In the Debug =
view, the=20
"creat, manage and run configurations' panel gives</FONT></P>
<P><FONT face=3DArial size=3D2>me a message "Program does not exist" =
message.&nbsp;=20
Can't find a way to force it to look in that directory</FONT></P>
<P><FONT face=3DArial size=3D2>and find the binary...&nbsp; Suspecting =
this is=20
related to having to "make" the project before the debugger </FONT></P>
<P><FONT face=3DArial size=3D2>can "see" it, I've tried to create a make =
target with=20
Ant as the "build command" but I only get the below</FONT></P>
<P><FONT face=3DArial size=3D2>message.&nbsp; Is there a way to drive =
the build with=20
ant AND have the debug tool find it?</FONT></P>
<P><FONT face=3DArial size=3D2><U>C-Build output:</U></FONT></P>
<P><FONT face=3DArial size=3D2>Error launching builder=20
(D:/ANT/apache-ant-1.6.1beta1/bin/ant all )</FONT></P>
<P><FONT face=3DArial size=3D2>(Exec error:Launching failed)</FONT></P>
<P><FONT face=3DArial size=3D2></FONT>&nbsp;</P>
<P><FONT face=3DArial size=3D2><U>Console output:</U></FONT></P>
<P><FONT face=3DArial size=3D2>Buildfile:=20
D:\eclipse\workspace\test\build.xml</FONT></P>
<P><FONT face=3DArial size=3D2>help:</FONT></P>
<P><FONT face=3DArial size=3D2>[echo] NMS test build file for =
Ant</FONT></P>
<P><FONT face=3DArial size=3D2>[echo] The following targets are =
defined:</FONT></P>
<P><FONT face=3DArial size=3D2>[echo] all - Compiles all .cpp =
files</FONT></P>
<P><FONT face=3DArial size=3D2>all:</FONT></P>
<P><FONT face=3DArial size=3D2>BUILD SUCCESSFUL</FONT></P>
<P><FONT face=3DArial size=3D2>Total time: 281=20
milliseconds</FONT></P></DIV></BODY></HTML>

------=_NextPart_000_0030_01C44A1D.66ABAB10--
Re: Using integrated debugger on Ant managed build [message #105056 is a reply to message #104709] Sat, 05 June 2004 01:15 Go to previous message
Eclipse UserFriend
Originally posted by: dschaefe.ca.ibm.com

This is a multi-part message in MIME format.

------=_NextPart_000_0078_01C44A9A.8B452500
Content-Type: text/plain;
charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable

The way I've used ant with the CDT is to download the cpptasks jar file =
from ant-contrib.sourceforge.net and install it into the Ant runtime =
(Windows->Preferences->Ant->Runtime, or something like that, can't =
remember at the moment). I then create a Standard Make project and turn =
off all options on when make runs, since I want to run Ant, not make, =
but I want the other goodies from the CDT. I then create a build.xml =
file in my project and create an External Tools Builder, specifying it =
to be an Ant builder and point it at my build.xml file. Finally I =
specify the info for the 'cc' task and I'm rocking.

My hope is to create a set of plugins to better support Ant with the CDT =
and to support combined Java/C++ projects. Other things beacon me at the =
moment so we'll see, but if anyone is interested, please drop me a line.

Hope this helps,
Doug

"bobk" <bobk@asg.com> wrote in message =
news:c9pvua$f8j$1@eclipse.org...
Thanks ahead if you can help: I want to use Ant to build my whole =
project (java & C++). To=20

prototype the c++ side I've created a 'hello' app and have created a =
build.xml for it. I debugged

it all outside of eclipse and then in eclipse was able to right click =
on the build.xml file and select

'Run Ant'. This, after a good delay, brought up a dialog that let me =
select the target and ran it.=20

Output from console is at bottom of this message. Great. =20

But now when I try to run the created binary in debugger, via a run =
configuration, I can not get

it to find the binary. In the Debug view, the "creat, manage and run =
configurations' panel gives

me a message "Program does not exist" message. Can't find a way to =
force it to look in that directory

and find the binary... Suspecting this is related to having to "make" =
the project before the debugger=20

can "see" it, I've tried to create a make target with Ant as the =
"build command" but I only get the below

message. Is there a way to drive the build with ant AND have the =
debug tool find it?

C-Build output:

Error launching builder (D:/ANT/apache-ant-1.6.1beta1/bin/ant all )

(Exec error:Launching failed)



Console output:

Buildfile: D:\eclipse\workspace\test\build.xml

help:

[echo] NMS test build file for Ant

[echo] The following targets are defined:

[echo] all - Compiles all .cpp files

all:

BUILD SUCCESSFUL

Total time: 281 milliseconds

------=_NextPart_000_0078_01C44A9A.8B452500
Content-Type: text/html;
charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META http-equiv=3DContent-Type content=3D"text/html; =
charset=3Diso-8859-1">
<META content=3D"MSHTML 6.00.2800.1400" name=3DGENERATOR>
<STYLE></STYLE>
</HEAD>
<BODY bgColor=3D#ffffff>
<DIV><FONT face=3DArial size=3D2>The way I've used ant with the CDT is =
to download=20
the cpptasks jar file from ant-contrib.sourceforge.net and install it =
into the=20
Ant runtime (Windows-&gt;Preferences-&gt;Ant-&gt;Runtime, or something =
like=20
that, can't remember at the moment). I then create a Standard Make =
project and=20
turn off all options on when make runs, since I want to run Ant, not =
make, but I=20
want the other goodies from the CDT. I then create a build.xml file in =
my=20
project and create an External Tools Builder, specifying it to be an Ant =
builder=20
and point it at my build.xml file. Finally I specify the info for the =
'cc' task=20
and I'm rocking.</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2>My hope is to create a set of plugins =
to better=20
support Ant with the CDT and to support combined Java/C++ projects. =
Other things=20
beacon me at the moment so we'll see, but if anyone is interested, =
please drop=20
me a line.</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
<DIV><FONT face=3DArial size=3D2>Hope this helps,</FONT></DIV>
<DIV><FONT face=3DArial size=3D2>Doug</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT>&nbsp;</DIV>
<BLOCKQUOTE dir=3Dltr=20
style=3D"PADDING-RIGHT: 0px; PADDING-LEFT: 5px; MARGIN-LEFT: 5px; =
BORDER-LEFT: #000000 2px solid; MARGIN-RIGHT: 0px">
<DIV>"bobk" &lt;<A href=3D"mailto:bobk@asg.com">bobk@asg.com</A>&gt; =
wrote in=20
message <A=20
=
href=3D"news:c9pvua$f8j$1@eclipse.org">news:c9pvua$f8j$1@eclipse.org</A>.=
...</DIV>
<DIV>
<P><FONT face=3DArial size=3D2>Thanks ahead if you can help:&nbsp; I =
want to use=20
Ant to build my whole project (java &amp; C++).&nbsp; =
To&nbsp;</FONT></P>
<P><FONT face=3DArial size=3D2>prototype the c++ side&nbsp;&nbsp;I've =
created a=20
'hello' app and have created a build.xml for it.&nbsp; I =
debugged</FONT></P>
<P><FONT face=3DArial size=3D2>it all outside of eclipse and then in =
eclipse was=20
able to right click on the build.xml file and select</FONT></P>
<P><FONT face=3DArial size=3D2>'Run Ant'.&nbsp; This, after a good =
delay, brought=20
up a dialog that let me select the target and ran it. </FONT></P>
<P><FONT face=3DArial size=3D2>Output from console is at bottom of =
this=20
message.&nbsp; Great.&nbsp; </FONT></P>
<P><FONT face=3DArial size=3D2>But now when I try to run the created =
binary in=20
debugger, via a run configuration, I can not get</FONT></P>
<P><FONT face=3DArial size=3D2>it to find the binary.&nbsp; In the =
Debug view, the=20
"creat, manage and run configurations' panel gives</FONT></P>
<P><FONT face=3DArial size=3D2>me a message "Program does not exist"=20
message.&nbsp; Can't find a way to force it to look in that=20
directory</FONT></P>
<P><FONT face=3DArial size=3D2>and find the binary...&nbsp; Suspecting =
this is=20
related to having to "make" the project before the debugger =
</FONT></P>
<P><FONT face=3DArial size=3D2>can "see" it, I've tried to create a =
make target=20
with Ant as the "build command" but I only get the below</FONT></P>
<P><FONT face=3DArial size=3D2>message.&nbsp; Is there a way to drive =
the build=20
with ant AND have the debug tool find it?</FONT></P>
<P><FONT face=3DArial size=3D2><U>C-Build output:</U></FONT></P>
<P><FONT face=3DArial size=3D2>Error launching builder=20
(D:/ANT/apache-ant-1.6.1beta1/bin/ant all )</FONT></P>
<P><FONT face=3DArial size=3D2>(Exec error:Launching =
failed)</FONT></P>
<P><FONT face=3DArial size=3D2></FONT>&nbsp;</P>
<P><FONT face=3DArial size=3D2><U>Console output:</U></FONT></P>
<P><FONT face=3DArial size=3D2>Buildfile:=20
D:\eclipse\workspace\test\build.xml</FONT></P>
<P><FONT face=3DArial size=3D2>help:</FONT></P>
<P><FONT face=3DArial size=3D2>[echo] NMS test build file for =
Ant</FONT></P>
<P><FONT face=3DArial size=3D2>[echo] The following targets are=20
defined:</FONT></P>
<P><FONT face=3DArial size=3D2>[echo] all - Compiles all .cpp =
files</FONT></P>
<P><FONT face=3DArial size=3D2>all:</FONT></P>
<P><FONT face=3DArial size=3D2>BUILD SUCCESSFUL</FONT></P>
<P><FONT face=3DArial size=3D2>Total time: 281=20
milliseconds</FONT></P></DIV></BLOCKQUOTE></BODY></HTML >

------=_NextPart_000_0078_01C44A9A.8B452500--
Previous Topic:CDT testing
Next Topic:M9 config typo?
Goto Forum:
  


Current Time: Thu Jul 17 19:41:39 EDT 2025

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

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

Back to the top