[embed] [patch] embed-head does not work with ant 1.5.3

2003-04-10 Thread Loïc Péron
Hi,

embed currently does not work with ant-1.5.3

1) RuntimeConfigurable2 does not compile because it uses a method
   introduced for 1.6:
   ih = IntrospectionHelper.getHelper(Project p, Class c);
   which can easily be replaced by:
   ih = IntrospectionHelper.getHelper(Class c);
   p.addBuildListener(ih);

2) PropertyHelper needs to be passed the properties set in the
   project to correctly replace them because it does not get these
   itself anymore in 1.6:
   ph.replaceProperties(null, value, null);
   must be replaced by:
   ph.replaceProperties(null, value, p.getProperties());

Costin, may you please apply the attached patch which contains these
changes and allows embed-head to compile and run with ant-1.5.3

PropertyHelper could also be synchronized with 1.6 to get a few
corrections.

Thanks all for your hard work.

-- 
Loïc Péron

phone:(33) 683 880 177
mailto:[EMAIL PROTECTED]--- RuntimeConfigurable2.java-1.8   Fri Mar 07 18:14:58 2003
+++ RuntimeConfigurable2.java   Thu Apr 10 14:10:01 2003
@@ -288,14 +288,15 @@
 
 if (attributes != null) {
 IntrospectionHelper ih =
-IntrospectionHelper.getHelper(p, target.getClass());
+IntrospectionHelper.getHelper(target.getClass());
+p.addBuildListener(ih);
 
 for (int i = 0; i  attributes.getLength(); i++) {
 String name= attributes.getQName(i);
 String value= attributes.getValue(i);
 
 // reflect these into the target
-value = ph.replaceProperties(null, value, null);
+value = ph.replaceProperties(null, value, p.getProperties());
 try {
 ih.setAttribute(p, target,
 name.toLowerCase(Locale.US), value);


Re: [PATCH] [17471] -projecthelp does not work with -quiet

2003-03-10 Thread Loïc Péron
 Well, we need to be sure it needs fixing :)

 This may sound silly but -projecthelp -verbose is more
 informative than the default listing, so the quiet
 listing should be less informative. The issue is how
 much less informative

Yes -projecthelp -verbose is much verbose about the
project targets, but also about any default tasks called
beforehand.

And -projecthelp -quiet should be less verbose ie silent
about the tasks called statically, yet still provide
what is asked ie -projecthelp.

My situation is I build a dynamic buildfile using some
static tasks, and then includes it in my main build
file. I'd like to get full projecthelp without task log.
Seems to me -projecthelp -quiet should tdo the job.

-- 
Loïc Péron

phone:(33) 683 880 177
mailto:[EMAIL PROTECTED]