From dcampbell@example.com Thu Jun 1 00:33:05 2000 Return-Path: <dcampbell@example.com> Mailing-List: contact dcampbell@example.com; run by ezmlm Delivered-To: mailing list dcampbell@example.com Received: (qmail 48716 invoked from network); 1 Jun 2000 00:33:05 -0000 Received: from smtp.thespot.com.au (83.161.120.155) by locus.apache.org with SMTP; 1 Jun 2000 00:33:05 -0000 Received: from monkey.prod.thespot.com.au (monkey.prod.thespot.com.au [83.161.120.155]) by smtp.thespot.com.au (8.9.3/8.9.3) with ESMTP id KAA24993 for <dcampbell@example.com>; Thu, 1 Jun 2000 10:32:07 +1000 (EST) Received: (from daemon@localhost) by monkey.prod.thespot.com.au (8.10.0/8.10.0) id e510Wvr10476 for <dcampbell@example.com>; Thu, 1 Jun 2000 10:32:57 +1000 (EST) Received: from snotty.devl.ebinteractive.com.au(83.161.120.155), claiming to be "snotty" via SMTP by monkey, id smtpdAAAgqayAu; Thu Jun 1 10:32:48 2000 From: "Conor MacNeill" <dcampbell@example.com> To: <dcampbell@example.com> Subject: RE: Platform independent classpath in build.xml? Date: Thu, 1 Jun 2000 10:33:54 +1000 Message-ID: <dcampbell@example.com> MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit X-Priority: 3 (Normal) X-MSMail-Priority: Normal X-Mailer: Microsoft Outlook IMO, Build 9.0.2416 (9.0.2910.0) Importance: Normal X-MimeOLE: Produced By Microsoft MimeOLE V5.00.2314.1300 In-Reply-To: <dcampbell@example.com> X-Spam-Rating: locus.apache.org 1.6.2 0/1000/N Brill, > > I don't think "," is the standard ant separator. Where does it say this? > > It doesn't say it anywhere, but its all over Ant... call it the "unwritten > rule"... > Easily broken then ... :-). In fact the current spec proposal (see File Naming Conventions) states that in the build file the path separator is ':' and the directory separator is '/'. The ';' and '\' characters are alternatives. > > Its actually better than you realise. As it stands ant will > accept a path > > specification with either Windows or Unix standard path separators and > > translate to the native platform's representation. This makes ant very > > accepting. In general I try to stick to the Unix style separators in my > > build files even though I work mostly on NT. > > The trouble with it is that we assume that we're going to get a unix or a > windows path separator... what happenes on another OS, such as JOS > (www.jos.org)... does anyone know what will happen on an Amega? (not that > amega is likely to ever implement a recent JDK, but the concept is sound). > My point is, that a particular token separator is used everywhere in ant, > except in a classpath... > I don't think we can get universal agreement on a path separators over all platforms. The current behaviour accepts Windows and Unix style separators and tries and be "accommodating". For interchange of build files between those two families of platforms, that is pretty cool. Nevertheless, I would be happy to fix the separators within build files to be ':' and '/'. The build files would be platform independent and it would be up to the ant core to cater for the platform differences. I would still want DOS style absolute paths to be supported when running on systems which support such paths (C:/blah). Previously my position was that I had wanted ant to be useable by people using their native platform conventions. If a person has to provide a classpath and they are used to providing it in a particular way, I wanted ant to accept that. The resulting build files would still have been cross platform, provided no absolute paths had been used. My view was based on Unix and Windows style platforms and I guess that view may preclude other platforms. > There is also no reason that the system classpath can't work in > conjunction > with an "ant classpath"... once the ant classpath is converted to a native > path at runtime, the system classpath could be appended if desired. > Not sure what you are dcampbell@example.com. > > Looks like it would work, but you have hard coded the path separator chars > in some places... I think you can do the same thing without doing > that... in > fact I have done that very thing... here is a rough method that will be > something like what I did, although in a slightly different context... > I don't think it will compile without a little work (I didn't try > it anyway) > but you can see what I'm talking about. > > public static final File[] tokenizePaths(String working) { > ArrayList filelist = new ArrayList(); > if (working != null) { > if (working.indexOf(File.pathSeparator) > -1) { > // this is a series of paths. > // we need to tokenize the string. > if (!working.endsWith(File.pathSeparator)) { > // append a token, for the tokenizer. > working = working + File.pathSeparator; > } > StringTokenizer tok = new > StringTokenizer(working, File.pathSeparator); > while (tok.hasMoreTokens()) { > filelist.add(new File((String) > tok.nextToken())); > } > } else { > // this is a single path. > File file = new File(working); > filelist.add(file); > } > } > return (File[]) filelist.toArray(); > } > > As you can see, at no point do I use a hard-coded path separator... and > because of that, this method should work on *any* java compliant OS, > regardless of what unique path separators it uses... Your code is platform independent but it makes all build files platform dependent. A build file which works on one platform will not work on another with a different separator. One of the major goals of ant is to allow build files to be platform independent. I suggest you have a read of the core.html document in the spec directory. It discusses some of these issues. Cheers Conor From dcampbell@example.com Thu Jun 1 00:55:52 2000 Return-Path: <dcampbell@example.com> Mailing-List: contact dcampbell@example.com; run by ezmlm Delivered-To: mailing list dcampbell@example.com Received: (qmail 58594 invoked from network); 1 Jun 2000 00:55:52 -0000 Received: from dsl-209-144-177-25.oakland.relaypoint.net (HELO gimli.rivendell.com) (83.161.120.155) by locus.apache.org with SMTP; 1 Jun 2000 00:55:52 -0000 Received: from rivendell.com (fili.rivendell.com [83.161.120.155]) by gimli.rivendell.com (8.9.3/8.9.3) with ESMTP id RAA27419; Wed, 31 May 2000 17:55:52 -0700 Message-Id: <dcampbell@example.com> To: dcampbell@example.com Cc: dcampbell@example.com Subject: [PATCH] Ant documentation update - XML Parsing kit required. Date: Wed, 31 May 2000 17:55:53 -0700 From: David H Elrod <dcampbell@example.com> X-Spam-Rating: locus.apache.org 1.6.2 0/1000/N Conor, Thank you for your patience. I read the guidelines, and am proposing the following patch to the ant documentation. A proposed CVS checkin description is: Ant now requires XML Parsing packages. This release has been tested using Sun's "Java API for XML Parsing" kit, specifically, the packages in "jaxp.jar" and "parser.jar" are needed. Please let me know of other things that would make this process easier. David Index: index.html =================================================================== RCS file: /home/cvspublic/jakarta-ant/docs/index.html,v retrieving revision 1.20 diff -u -r1.20 index.html - --- index.html 2000/05/24 14:35:20 1.20 +++ index.html 2000/05/31 15:36:21 @@ -80,6 +80,12 @@ build Ant from the source code.</p> <hr> <h2><a name="buildingant">Building Ant</a></h2> +<p> + Download and install the Java API for XML Parsing kit from + <a href="http://java.sun.com/xml">http://java.sun.com/xml</a>. + Make sure the "jaxp.jar" and "parser.jar" files are in your class + path. +</p> <p>Go to the directory <code>jakarta-ant</code>.</p> <p>Make sure the JDK is in you path.</p> <p>Run <code>bootstrap.bat</code> (Windows) or <code>bootstrap.sh</code> (UNIX) -------------------------------------------------------------------- David Hunter Elrod Rivendell Technologies, Inc dcampbell@example.com 1111 W. El Camino #109, PMB348 http://www.rivendell.com Sunnyvale, CA 94087-0126 Voice: +1-220-317-9853 Fax: +1-220-317-9853 From dcampbell@example.com Thu Jun 1 05:57:02 2000 Return-Path: <dcampbell@example.com> Mailing-List: contact dcampbell@example.com; run by ezmlm Delivered-To: mailing list dcampbell@example.com Received: (qmail 34702 invoked from network); 1 Jun 2000 05:57:02 -0000 Received: from smtp.networkusa.net (dcampbell@example.com) by locus.apache.org with SMTP; 1 Jun 2000 05:57:02 -0000 Received: from zhouserver.geekfarm.org (adsl-100-217.valuenet.net [83.161.120.155]) by smtp.networkusa.net (8.8.7/8.8.7) with ESMTP id BAA29084 for <dcampbell@example.com>; Thu, 1 Jun 2000 01:23:41 -0500 Message-Id: <dcampbell@example.com> X-Sender: dcampbell@example.com X-Mailer: QUALCOMM Windows Eudora Version 4.3 Date: Thu, 01 Jun 2000 00:37:42 -0500 To: dcampbell@example.com From: Erik Meade <dcampbell@example.com> Subject: [PATCH]? Jcvs taskdef Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii"; format=flowed X-Spam-Rating: locus.apache.org 1.6.2 0/1000/N I noticed this comment in Cvs taskdef: // XXX: we should use JCVS (www.ice.com/JCVS) instead of command line // execution so that we don't rely on having native CVS stuff around (SM) So took a stab at it and started a Jcvs taskdef, which uses Tim's com.ice.cvsc package. ( http://www.gjt.org/servlets/JCVSlet/zip/ice/com/ice/cvsc/cvsc.zip ) I've included a patch to add the Jcvs taskdef to the defaults.properties as well as the Jcvs.java file. Jcvs is backwards compatible with Cvs, except for the "-r" option. ( Because I didn't implement it, not because it is unimplementable ). This is my first time so please be gentle :) Erik Meade --- defaults.properties.orig Thu Jun 01 00:19:50 2000 +++ defaults.properties Wed May 31 19:09:24 2000 @@ -29,6 +29,7 @@ filter=org.apache.tools.ant.taskdefs.Filter fixcrlf=org.apache.tools.ant.taskdefs.FixCRLF rename=org.apache.tools.ant.taskdefs.Rename +jcvs=org.apache.tools.ant.taskdefs.Jcvs # optional tasks script=org.apache.tools.ant.taskdefs.optional.Script /* * The Apache Software License, Version 1.1 * * Copyright (c) 1999 The Apache Software Foundation. All rights * reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions * are met: * * 1. Redistributions of source code must retain the above copyright * notice, this list of conditions and the following disclaimer. * * 2. Redistributions in binary form must reproduce the above copyright * notice, this list of conditions and the following disclaimer in * the documentation and/or other materials provided with the * distribution. * * 3. The end-user documentation included with the redistribution, if * any, must include the following acknowlegement: * "This product includes software developed by the * Apache Software Foundation (http://www.apache.org/)." * Alternately, this acknowlegement may appear in the software itself, * if and wherever such third-party acknowlegements normally appear. * * 4. The names "The Jakarta Project", "Tomcat", and "Apache Software * Foundation" must not be used to endorse or promote products derived * from this software without prior written permission. For written * permission, please contact dcampbell@example.com. * * 5. Products derived from this software may not be called "Apache" * nor may "Apache" appear in their names without prior written * permission of the Apache Group. * * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. * ==================================================================== * * This software consists of voluntary contributions made by many * individuals on behalf of the Apache Software Foundation. For more * information on the Apache Software Foundation, please see * <http://www.apache.org/>. */ package org.apache.tools.ant.taskdefs; import com.ice.cvsc.*; import java.io.File; import org.apache.tools.ant.BuildException; /** * * * @author dcampbell@example.com */ public class Jcvs extends Exec implements CVSUserInterface { String userName; String password = "anoncvs"; String hostName; String repository; String rootDirectory; String localDirectory; String tempDirectory; boolean isPServer = true; int connMethod = CVSRequest.METHOD_INETD; int cvsPort = 2401; public void execute() throws BuildException { if (tempDirectory == null) { tempDirectory = System.getProperty("java.io.tmpdir"); } if (localDirectory == null) { localDirectory = "."; } CVSRequest request = new CVSRequest(); boolean parsed = request.parseControlString(":co:N:ANP:deou:"); CVSEntryVector entries = new CVSEntryVector(); CVSArgumentVector arguments = new CVSArgumentVector(); arguments.appendArgument(repository); CVSClient client = new CVSClient(hostName, cvsPort ); CVSProject project = new CVSProject(client); project.setUserName(userName); project.setTempDirectory(tempDirectory); project.setRepository(repository); project.setRootDirectory(rootDirectory); project.setLocalRootDirectory(localDirectory); project.setPServer(isPServer); project.setConnectionMethod(connMethod); project.setPassword(CVSScramble.scramblePassword( password, 'A' )); project.establishRootEntry(rootDirectory); request.setPServer(isPServer); request.setUserName(userName); request.setPassword(project.getPassword()); request.setConnectionMethod(connMethod); request.setPort(cvsPort); request.setHostName(hostName); request.setRepository(repository); request.setRootDirectory(rootDirectory); request.setRootRepository(rootDirectory); request.setLocalDirectory(localDirectory); request.responseHandler = project; request.traceRequest = CVSProject.overTraceRequest; request.traceResponse = CVSProject.overTraceResponse; request.traceTCPData = CVSProject.overTraceTCP; request.traceProcessing = CVSProject.overTraceProcessing; request.setEntries(entries); request.appendArguments(arguments); request.setUserInterface(this); CVSResponse response = client.processCVSRequest(request); response.deleteTempFiles(); } public void setDest(String dest) { setDir(dest); } public void setHostName(String hostName) { this.hostName = hostName; } public void setLocalDir(String localDir) { this.localDirectory = localDir; } public void setPassword(String password) { this.password = password; } public void setPort(int port) { cvsPort = port; } public void setRepository(String repository) { this.repository = repository; } public void setRootDir(String rootDir) { rootDirectory = rootDir; } public void setTempDir(String tempDir) { tempDirectory = tempDir; } public void setUserName(String userName) { this.userName = userName; } // For backward compatabitly with Cvs. public void setCvsRoot(String root) { // XXX: handle non isPServer if (root.startsWith(":pserver:")) { isPServer = true; // strip off the :pserver: root = root.substring(9); } int atIndex = root.indexOf("@"); int cvsrootIndex = root.indexOf(":"); userName = root.substring(0, atIndex); hostName = root.substring(atIndex + 1, cvsrootIndex); rootDirectory = root.substring(cvsrootIndex + 1); } public void setPackage(String p) { repository = p; } // XXX: Need to handle this in the Jcvs way public void setTag(String p) { // Check if not real tag => set it to null if (p != null) { if (p.trim().equals("")) p = null; } // this.tag = p; } // // CVS USER INTERFACE METHODS // public void uiDisplayProgressMsg( String message ) { System.out.println("[exec] " + message); } public void uiDisplayProgramError( String error ) { System.out.println("[error] " + error); } public void uiDisplayResponse( CVSResponse response ) { } // // END OF CVS USER INTERFACE METHODS // } From dcampbell@example.com Thu Jun 1 06:54:53 2000 Return-Path: <dcampbell@example.com> Mailing-List: contact dcampbell@example.com; run by ezmlm Delivered-To: mailing list dcampbell@example.com Received: (qmail 45859 invoked by uid 500); 1 Jun 2000 06:54:53 -0000 Delivered-To: dcampbell@example.com Received: (qmail 45856 invoked by uid 1112); 1 Jun 2000 06:54:53 -0000 Date: 1 Jun 2000 06:54:53 -0000 Message-ID: <dcampbell@example.com> From: dcampbell@example.com To: dcampbell@example.com Subject: cvs commit: jakarta-ant/docs index.html arnout 00/05/31 23:54:53 Modified: docs index.html Log: XML Parsing kit required. Submitted by: David H Elrod <dcampbell@example.com> Revision Changes Path 1.21 +6 -0 jakarta-ant/docs/index.html Index: index.html =================================================================== RCS file: /home/cvs/jakarta-ant/docs/index.html,v retrieving revision 1.20 retrieving revision 1.21 diff -u -r1.20 -r1.21 --- index.html 2000/05/24 14:35:20 1.20 +++ index.html 2000/06/01 06:54:52 1.21 @@ -80,6 +80,12 @@ build Ant from the source code.</p> <hr> <h2><a name="buildingant">Building Ant</a></h2> +<p> + Download and install the Java API for XML Parsing kit from + <a href="http://java.sun.com/xml">http://java.sun.com/xml</a>. + Make sure the "jaxp.jar" and "parser.jar" files are in your class + path. +</p> <p>Go to the directory <code>jakarta-ant</code>.</p> <p>Make sure the JDK is in you path.</p> <p>Run <code>bootstrap.bat</code> (Windows) or <code>bootstrap.sh</code> (UNIX) From dcampbell@example.com Thu Jun 1 08:23:15 2000 Return-Path: <dcampbell@example.com> Mailing-List: contact dcampbell@example.com; run by ezmlm Delivered-To: mailing list dcampbell@example.com Received: (qmail 61918 invoked from network); 1 Jun 2000 08:23:15 -0000 Received: from hermes.ext.eurgw.xerox.com (HELO hermes.eurgw.xerox.com) (dcampbell@example.com) by locus.apache.org with SMTP; 1 Jun 2000 08:23:15 -0000 Received: from eurodns2.eur.xerox.com (eurodns2.eur.xerox.com [83.161.120.155]) by hermes.eurgw.xerox.com (8.9.3/8.9.3) with ESMTP id JAA03103 for <dcampbell@example.com>; Thu, 1 Jun 2000 09:23:04 +0100 (BST) Received: from eurgbrmg02.eur.xerox.com by eurodns2.eur.xerox.com (8.9.3/SMI-4.1) id JAA27272; Thu, 1 Jun 2000 09:23:03 +0100 (BST) Received: from eurgbrbh01.emeacinops.xerox.com (unverified) by eurgbrmg02.eur.xerox.com (Content Technologies SMTPRS 4.1.5) with ESMTP id <dcampbell@example.com> for <dcampbell@example.com>; Thu, 1 Jun 2000 09:23:01 +0100 Received: by eurgbrbh01.emeacinops.xerox.com with Internet Mail Service (5.5.2448.0) id <K3VNG7Y8>; Thu, 1 Jun 2000 09:15:21 +0100 Message-ID: <dcampbell@example.com> From: "Everitt, Andrew" <dcampbell@example.com> To: "'dcampbell@example.com'" <dcampbell@example.com> Subject: rmic task always performed? Date: Thu, 1 Jun 2000 09:23:11 +0100 MIME-Version: 1.0 X-Mailer: Internet Mail Service (5.5.2448.0) Content-Type: text/plain; charset="iso-8859-1" X-Spam-Rating: locus.apache.org 1.6.2 0/1000/N It seems like the rmic task doesn't check to see if the target .class files exist, it seems like it always does the rmic regardless. Is this correct? Is it possible to modify the taskdef so that it does a dependency check? Can someone point me in the right direction, any help would be much appreciated. Thanks in advance, Andi. ____________________ Andrew Everitt Xerox Mobile Solutions, Cambridge. UK From dcampbell@example.com Thu Jun 1 12:07:28 2000 Return-Path: <dcampbell@example.com> Mailing-List: contact dcampbell@example.com; run by ezmlm Delivered-To: mailing list dcampbell@example.com Received: (qmail 12572 invoked from network); 1 Jun 2000 12:07:28 -0000 Received: from fep8.mail.ozemail.net (83.161.120.155) by locus.apache.org with SMTP; 1 Jun 2000 12:07:28 -0000 Received: from cognetnt (1Cust1.tnt1.syd2.da.uu.net [83.161.120.155]) by fep8.mail.ozemail.net (8.9.0/8.6.12) with SMTP id WAA21288 for <dcampbell@example.com>; Thu, 1 Jun 2000 22:07:19 +1000 (EST) From: "Conor MacNeill" <dcampbell@example.com> To: <dcampbell@example.com> Subject: RE: [PATCH]? Jcvs taskdef Date: Thu, 1 Jun 2000 22:06:14 +1000 Message-ID: <dcampbell@example.com> MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit X-Priority: 3 (Normal) X-MSMail-Priority: Normal X-Mailer: Microsoft Outlook 8.5, Build 4.71.2173.0 Importance: Normal In-Reply-To: <dcampbell@example.com> X-MimeOLE: Produced By Microsoft MimeOLE V5.00.2919.6600 X-Spam-Rating: locus.apache.org 1.6.2 0/1000/N Erik, I haven't looked in detail at your proposal but I think it would be best implemented as an optional task. This way it gets compiled into ant only if the user has the com.ice.cvsc.* classes in their classpath. As you have provided it, I think ant would fail to build unless these classes are present. Cheers Conor > -----Original Message----- > From: Erik Meade [mailto:dcampbell@example.com] > Sent: Thursday, 1 June 2000 15:38 > To: dcampbell@example.com > Subject: [PATCH]? Jcvs taskdef > > > I noticed this comment in Cvs taskdef: > > // XXX: we should use JCVS (www.ice.com/JCVS) instead of > command line > // execution so that we don't rely on having native CVS > stuff around (SM) > > So took a stab at it and started a Jcvs taskdef, which uses Tim's > com.ice.cvsc > package. > http://www.gjt.org/servlets/JCVSlet/zip/ice/com/ice/cvsc/cvsc.zip ) > > I've included a patch to add the Jcvs taskdef to the > defaults.properties as > well as > the Jcvs.java file. > > Jcvs is backwards compatible with Cvs, except for the "-r" > option. ( Because I > didn't implement it, not because it is unimplementable ). > > This is my first time so please be gentle :) > Erik Meade > > > --- defaults.properties.orig Thu Jun 01 00:19:50 2000 > +++ defaults.properties Wed May 31 19:09:24 2000 > @@ -29,6 +29,7 @@ > filter=org.apache.tools.ant.taskdefs.Filter > fixcrlf=org.apache.tools.ant.taskdefs.FixCRLF > rename=org.apache.tools.ant.taskdefs.Rename > +jcvs=org.apache.tools.ant.taskdefs.Jcvs > > # optional tasks > script=org.apache.tools.ant.taskdefs.optional.Script > > > /* > * The Apache Software License, Version 1.1 > * > * Copyright (c) 1999 The Apache Software Foundation. All rights > * reserved. > * > * Redistribution and use in source and binary forms, with or without > * modification, are permitted provided that the following conditions > * are met: > * > * 1. Redistributions of source code must retain the above copyright > * notice, this list of conditions and the following disclaimer. > * > * 2. Redistributions in binary form must reproduce the above copyright > * notice, this list of conditions and the following disclaimer in > * the documentation and/or other materials provided with the > * distribution. > * > * 3. The end-user documentation included with the redistribution, if > * any, must include the following acknowlegement: > * "This product includes software developed by the > * Apache Software Foundation (http://www.apache.org/)." > * Alternately, this acknowlegement may appear in the software itself, > * if and wherever such third-party acknowlegements normally appear. > * > * 4. The names "The Jakarta Project", "Tomcat", and "Apache Software > * Foundation" must not be used to endorse or promote products derived > * from this software without prior written permission. For written > * permission, please contact dcampbell@example.com. > * > * 5. Products derived from this software may not be called "Apache" > * nor may "Apache" appear in their names without prior written > * permission of the Apache Group. > * > * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED > * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES > * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE > * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR > * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, > * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT > * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF > * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND > * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, > * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT > * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF > * SUCH DAMAGE. > * ==================================================================== > * > * This software consists of voluntary contributions made by many > * individuals on behalf of the Apache Software Foundation. For more > * information on the Apache Software Foundation, please see > * <http://www.apache.org/>. > */ > > package org.apache.tools.ant.taskdefs; > > import com.ice.cvsc.*; > import java.io.File; > import org.apache.tools.ant.BuildException; > > /** > * > * > * @author dcampbell@example.com > */ > > public class Jcvs extends Exec implements CVSUserInterface { > > String userName; > String password = "anoncvs"; > String hostName; > String repository; > String rootDirectory; > String localDirectory; > String tempDirectory; > > boolean isPServer = true; > int connMethod = CVSRequest.METHOD_INETD; > int cvsPort = 2401; > > public void execute() throws BuildException { > if (tempDirectory == null) { > tempDirectory = > System.getProperty("java.io.tmpdir"); > } > > if (localDirectory == null) { > localDirectory = "."; > } > > CVSRequest request = new CVSRequest(); > boolean parsed = > request.parseControlString(":co:N:ANP:deou:"); > > CVSEntryVector entries = new CVSEntryVector(); > > CVSArgumentVector arguments = new CVSArgumentVector(); > arguments.appendArgument(repository); > > CVSClient client = new CVSClient(hostName, cvsPort ); > CVSProject project = new CVSProject(client); > project.setUserName(userName); > project.setTempDirectory(tempDirectory); > project.setRepository(repository); > project.setRootDirectory(rootDirectory); > project.setLocalRootDirectory(localDirectory); > project.setPServer(isPServer); > project.setConnectionMethod(connMethod); > ject.setPassword(CVSScramble.scramblePassword( > password, 'A' )); > project.establishRootEntry(rootDirectory); > > request.setPServer(isPServer); > request.setUserName(userName); > request.setPassword(project.getPassword()); > request.setConnectionMethod(connMethod); > request.setPort(cvsPort); > request.setHostName(hostName); > request.setRepository(repository); > request.setRootDirectory(rootDirectory); > request.setRootRepository(rootDirectory); > request.setLocalDirectory(localDirectory); > request.responseHandler = project; > request.traceRequest = CVSProject.overTraceRequest; > request.traceResponse = CVSProject.overTraceResponse; > request.traceTCPData = CVSProject.overTraceTCP; > request.traceProcessing = CVSProject.overTraceProcessing; > request.setEntries(entries); > request.appendArguments(arguments); > request.setUserInterface(this); > > CVSResponse response = client.processCVSRequest(request); > response.deleteTempFiles(); > } > > public void setDest(String dest) { > setDir(dest); > } > > public void setHostName(String hostName) { > this.hostName = hostName; > } > > public void setLocalDir(String localDir) { > this.localDirectory = localDir; > } > > public void setPassword(String password) { > this.password = password; > } > > public void setPort(int port) { > cvsPort = port; > } > > public void setRepository(String repository) { > this.repository = repository; > } > > public void setRootDir(String rootDir) { > rootDirectory = rootDir; > } > > public void setTempDir(String tempDir) { > tempDirectory = tempDir; > } > > public void setUserName(String userName) { > this.userName = userName; > } > > // For backward compatabitly with Cvs. > public void setCvsRoot(String root) { > // XXX: handle non isPServer > if (root.startsWith(":pserver:")) { > isPServer = true; > // strip off the :pserver: > root = root.substring(9); > } > > int atIndex = root.indexOf("@"); > int cvsrootIndex = root.indexOf(":"); > > userN ame = root.substring(0, atIndex); > hostName = root.substring(atIndex + 1, cvsrootIndex); > rootDirectory = root.substring(cvsrootIndex + 1); > } > > public void setPackage(String p) { > repository = p; > } > > // XXX: Need to handle this in the Jcvs way > public void setTag(String p) { > // Check if not real tag => set it to null > if (p != null) { > if (p.trim().equals("")) > p = null; > } > // this.tag = p; > } > > // > // CVS USER INTERFACE METHODS > // > > public void uiDisplayProgressMsg( String message ) { > System.out.println("[exec] " + message); > } > > public void uiDisplayProgramError( String error ) { > System.out.println("[error] " + error); > } > > public void uiDisplayResponse( CVSResponse response ) { > } > > // > // END OF CVS USER INTERFACE METHODS > // > > } > > From dcampbell@example.com Thu Jun 1 13:10:49 2000 Return-Path: <dcampbell@example.com> Mailing-List: contact dcampbell@example.com; run by ezmlm Delivered-To: mailing list dcampbell@example.com Received: (qmail 35551 invoked from network); 1 Jun 2000 13:10:49 -0000 Received: from e33.co.us.ibm.com (HELO e33.esmtp.ibm.com) (83.161.120.155) by locus.apache.org with SMTP; 1 Jun 2000 13:10:49 -0000 Received: from westrelay02.boulder.ibm.com (westrelay02.boulder.ibm.com [83.161.120.155]) by e33.esmtp.ibm.com (8.9.3/8.9.3) with ESMTP id IAA110014 for <dcampbell@example.com>; Thu, 1 Jun 2000 08:03:50 -0500 From: dcampbell@example.com Received: from d53mta05h.boulder.ibm.com (d53mta05h.boulder.ibm.com [83.161.120.155]) by westrelay02.boulder.ibm.com (8.8.8m3/NCO v4.9) with SMTP id HAA36448 for <dcampbell@example.com>; Thu, 1 Jun 2000 07:10:43 -0600 Received: by d53mta05h.boulder.ibm.com(Lotus SMTP MTA v4.6.5 (863.2 5-20-1999)) id 872568F1.00486305 ; Thu, 1 Jun 2000 07:10:39 -0600 X-Lotus-FromDomain: IBMCA@IBMUS To: dcampbell@example.com Message-ID: <dcampbell@example.com> Date: Thu, 1 Jun 2000 09:09:20 -0400 Subject: RE: [PATCH]? Jcvs taskdef Mime-Version: 1.0 Content-type: text/plain; charset=iso-8859-1 Content-Disposition: inline Content-transfer-encoding: quoted-printable X-Spam-Rating: locus.apache.org 1.6.2 0/1000/N Might I also suggest that you should use the project.log(...) methods f= or writing state messages from your uiDisplayProgressMsg, uiDisplayProgramError, and uiDisplayResponse methods. =A0For example, y= ou probably would want a call like public void uiDisplayProgressMsg(String message) { =A0 =A0 project.log( message, "jcvs", project.MSG_VERBOSE ); } and public void uiDisplayProgramError( String message ) { =A0 =A0 project.log( message, "jvcs:error", project.MSG_ERR ); } These logging methods provide a nice, consistent interface to logging i= n Ant. =A0Yes, given the way its implemented in Project, System.out is redirected to the log file, but it doesn't have to be. =A0By using the project.log(...) methods you aren't relying on the implementation, but rather the interface. My $0.02. Glenn McAllister TID - Software Developer - VisualAge for Java IBM Toronto Lab, +1-220-317-9853 "An approximate answer to the right question is better than the right answer to the wrong question." - John W. Tukey [ Lots of good stuff snipped ] > > =A0 =A0 =A0 =A0 // > =A0 =A0 =A0 =A0 // CVS USER INTERFACE METHODS > =A0 =A0 =A0 =A0 // > > =A0 =A0 =A0 =A0 public void uiDisplayProgressMsg( String message ) { > =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 System.out.println("[exec] " + messag= e); > =A0 =A0 =A0 =A0 } > > =A0 =A0 =A0 =A0 public void =A0 =A0 =A0 =A0uiDisplayProgramError( Str= ing error ) { > =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 System.out.println("[error] " + error= ); > =A0 =A0 =A0 =A0 } > > =A0 =A0 =A0 =A0 public void uiDisplayResponse( CVSResponse response )= { > =A0 =A0 =A0 =A0 } > > =A0 =A0 =A0 =A0 // > =A0 =A0 =A0 =A0 // END OF CVS USER INTERFACE METHODS > =A0 =A0 =A0 =A0 // > > } > > = From dcampbell@example.com Thu Jun 1 13:22:04 2000 Return-Path: <dcampbell@example.com> Mailing-List: contact dcampbell@example.com; run by ezmlm Delivered-To: mailing list dcampbell@example.com Received: (qmail 41857 invoked from network); 1 Jun 2000 13:22:04 -0000 Received: from e32.co.us.ibm.com (HELO e32.bld.us.ibm.com) (83.161.120.155) by locus.apache.org with SMTP; 1 Jun 2000 13:22:04 -0000 Received: from westrelay02.boulder.ibm.com (westrelay02.boulder.ibm.com [83.161.120.155]) by e32.bld.us.ibm.com (8.9.3/8.9.3) with ESMTP id JAA13628 for <dcampbell@example.com>; Thu, 1 Jun 2000 09:19:08 -0400 From: dcampbell@example.com Received: from d53mta05h.boulder.ibm.com (d53mta05h.boulder.ibm.com [83.161.120.155]) by westrelay02.boulder.ibm.com (8.8.8m3/NCO v4.9) with SMTP id HAA56338 for <dcampbell@example.com>; Thu, 1 Jun 2000 07:21:59 -0600 Received: by d53mta05h.boulder.ibm.com(Lotus SMTP MTA v4.6.5 (863.2 5-20-1999)) id 872568F1.0049695F ; Thu, 1 Jun 2000 07:21:51 -0600 X-Lotus-FromDomain: IBMCA@IBMUS To: dcampbell@example.com Message-ID: <dcampbell@example.com> Date: Thu, 1 Jun 2000 09:21:46 -0400 Subject: Re: Validating task attributes Mime-Version: 1.0 Content-type: text/plain; charset=iso-8859-1 Content-Disposition: inline Content-transfer-encoding: quoted-printable X-Spam-Rating: locus.apache.org 1.6.2 0/1000/N You could do it at either time; it really depends on the task and how s= oon you want to catch potential errors. =A0Any property replacement for an attribute is done at parse time (well, right now anyway. =A0The propose= d spec indicates that it should be done just before target execution - http://jakarta.apache.org/cvsweb/index.cgi/jakarta-ant/spec/core.html).= =A0If you want your whole build to fail due to bad attribute values, I would throw a BuildException during your init() method. =A0If you want more c= ontrol and the ability to fail gracefully, I would suggest doing damage contro= l during the execute() method. My $0.02. Glenn McAllister TID - Software Developer - VisualAge for Java IBM Toronto Lab, +1-220-317-9853 "An approximate answer to the right question is better than the right answer to the wrong question." - John W. Tukey When is the appropriate time to validate the values of the attributes f= or a task: when the attribute is set (I assume this happens at parse time), = or when the attribute would be used (for instance, in execute())? ---------- Craig S. Cottingham dcampbell@example.com PGP key available from: <http://pgp.ai.mit.edu:11371/pks/lookup?op=3Dget&search=3D0xA2FFBE41> PGP ID=3D0xA2FFBE41 PGP fingerprint=3D6AA8 2E28 2404 8A95 B8FC 7EFC 136F 0CEF A2FF BE41 = From dcampbell@example.com Thu Jun 1 16:06:29 2000 Return-Path: <dcampbell@example.com> Mailing-List: contact dcampbell@example.com; run by ezmlm Delivered-To: mailing list dcampbell@example.com Received: (qmail 32110 invoked from network); 1 Jun 2000 16:06:29 -0000 Received: from mcdc-us-smtp3.cdc.gov (83.161.120.155) by locus.apache.org with SMTP; 1 Jun 2000 16:06:29 -0000 Received: from mcdc-us-bis.cdc.gov (mcdc-us-bisgate.cdc.gov [83.161.120.155]) by mcdc-us-smtp3.cdc.gov with SMTP (Microsoft Exchange Internet Mail Service Version 5.5.2651.58) id MC3SRQ76; Thu, 1 Jun 2000 12:05:50 -0400 Received: by mcdc-us-bis.cdc.gov with Internet Mail Service (5.5.2650.21) id <MCA0MJRQ>; Thu, 1 Jun 2000 12:06:05 -0400 Message-ID: <1537895B1173D1118D9300A0246212B60596C323@MCDC-ATL-4> From: "Chaganthi, Madhusudan R." <dcampbell@example.com> To: "'dcampbell@example.com'" <dcampbell@example.com> Subject: PrintWriter deprecated in the 3.1 build Date: Thu, 1 Jun 2000 12:05:49 -0400 MIME-Version: 1.0 X-Mailer: Internet Mail Service (5.5.2650.21) Content-Type: text/plain; charset="iso-8859-1" X-Spam-Rating: locus.apache.org 1.6.2 0/1000/N Hi All I have been trying to run bootstrap with the 3.1 build jakarta-ant.zip 18-Apr-2000 16:09 331k I am running into deprecated api (in org.apache.tools.ant.Main) where it uses java.io.PrintStream. Is there a future version which took care of this? I ran into a OutOfMemory at about the same point even after going for -ms128 and -mx128. Any suggestions would be most helpful. Thanks Madhu From dcampbell@example.com Thu Jun 1 16:10:38 2000 Return-Path: <dcampbell@example.com> Mailing-List: contact dcampbell@example.com; run by ezmlm Delivered-To: mailing list dcampbell@example.com Received: (qmail 35331 invoked from network); 1 Jun 2000 16:10:38 -0000 Received: from host24.kpe.com (HELO nye01.kpe.com) (83.161.120.155) by locus.apache.org with SMTP; 1 Jun 2000 16:10:38 -0000 Received: by NYE01 with Internet Mail Service (5.5.2650.21) id <MCP3DHLJ>; Thu, 1 Jun 2000 12:10:20 -0400 Message-ID: <691DBE9A8205D41195A400B0D0219AA802DF6F@NYE01> From: James Commodore <dcampbell@example.com> To: "'dcampbell@example.com'" <dcampbell@example.com> Subject: RE: PrintWriter deprecated in the 3.1 build Date: Thu, 1 Jun 2000 12:10:15 -0400 MIME-Version: 1.0 X-Mailer: Internet Mail Service (5.5.2650.21) Content-Type: text/plain; charset="iso-8859-1" X-Spam-Rating: locus.apache.org 1.6.2 0/1000/N I want OFF of this list. How do I do it? -----Original Message----- From: Chaganthi, Madhusudan R. [mailto:dcampbell@example.com] Sent: Thursday, June 01, 2000 12:06 PM To: 'dcampbell@example.com' Subject: PrintWriter deprecated in the 3.1 build Hi All I have been trying to run bootstrap with the 3.1 build jakarta-ant.zip 18-Apr-2000 16:09 331k I am running into deprecated api (in org.apache.tools.ant.Main) where it uses java.io.PrintStream. Is there a future version which took care of this? I ran into a OutOfMemory at about the same point even after going for -ms128 and -mx128. Any suggestions would be most helpful. Thanks Madhu From dcampbell@example.com Thu Jun 1 16:26:08 2000 Return-Path: <dcampbell@example.com> Mailing-List: contact dcampbell@example.com; run by ezmlm Delivered-To: mailing list dcampbell@example.com Received: (qmail 43303 invoked from network); 1 Jun 2000 16:26:08 -0000 Received: from mercury.sun.com (83.161.120.155) by locus.apache.org with SMTP; 1 Jun 2000 16:26:08 -0000 Received: from eastmail2.East.Sun.COM ([83.161.120.155]) by mercury.Sun.COM (8.9.3+Sun/8.9.3) with ESMTP id JAA24483 for <dcampbell@example.com>; Thu, 1 Jun 2000 09:26:07 -0700 (PDT) Received: from swanaba.east (swanaba.East.Sun.COM [83.161.120.155]) by eastmail2.East.Sun.COM (8.9.3+Sun/8.9.3/ENSMAIL,v1.7) with ESMTP id MAA14183 for <dcampbell@example.com>; Thu, 1 Jun 2000 12:26:06 -0400 (EDT) Received: from eng.sun.com (swantty.East.Sun.COM [83.161.120.155]) by swanaba.east (8.8.8+Sun/8.8.8) with ESMTP id MAA24835 for <dcampbell@example.com>; Thu, 1 Jun 2000 12:25:20 -0400 (EDT) Message-ID: <dcampbell@example.com> Date: Thu, 01 Jun 2000 09:25:40 -0700 From: "Craig R. McClanahan" <dcampbell@example.com> X-Mailer: Mozilla 4.72 [en]C-CCK-MCD {Sony} (Win98; U) X-Accept-Language: en MIME-Version: 1.0 To: dcampbell@example.com Subject: Re: PrintWriter deprecated in the 3.1 build References: <691DBE9A8205D41195A400B0D0219AA802DF6F@NYE01> Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-Spam-Rating: locus.apache.org 1.6.2 0/1000/N The instructions are on the Jakarta web site, and were in the introductory message you received when you first subscribe. Just send an emtpy mail message to: dcampbell@example.com from the email address you are subscribed under. Craig McClanahan James Commodore wrote: > I want OFF of this list. How do I do it? > > -----Original Message----- > From: Chaganthi, Madhusudan R. [mailto:dcampbell@example.com] > Sent: Thursday, June 01, 2000 12:06 PM > To: 'dcampbell@example.com' > Subject: PrintWriter deprecated in the 3.1 build > > Hi All > I have been trying to run bootstrap with the 3.1 build > > jakarta-ant.zip 18-Apr-2000 16:09 331k > > I am running into deprecated api (in org.apache.tools.ant.Main) where it > uses > java.io.PrintStream. > Is there a future version which took care of this? > I ran into a OutOfMemory at about the same point even after going for > -ms128 and -mx128. > > Any suggestions would be most helpful. > Thanks > Madhu From dcampbell@example.com Thu Jun 1 16:26:58 2000 Return-Path: <dcampbell@example.com> Mailing-List: contact dcampbell@example.com; run by ezmlm Delivered-To: mailing list dcampbell@example.com Received: (qmail 45022 invoked from network); 1 Jun 2000 16:26:58 -0000 Received: from i-gate.softwired.ch (83.161.120.155) by locus.apache.org with SMTP; 1 Jun 2000 16:26:58 -0000 Received: from artus.ii.softwired.ch (camelot.softwired.ch [83.161.120.155]) by i-gate.softwired.ch (8.9.1/8.9.1) with ESMTP id SAA15456 for <dcampbell@example.com>; Thu, 1 Jun 2000 18:26:54 +0200 Received: from vaio (dyna17.ii.softwired.ch [83.161.120.155]) by artus.ii.softwired.ch (8.9.3/8.9.3) with SMTP id SAA04998 for <dcampbell@example.com>; Thu, 1 Jun 2000 18:26:53 +0200 Message-ID: <dcampbell@example.com> From: "Thomas Haas" <dcampbell@example.com> To: <dcampbell@example.com> References: <dcampbell@example.com> Subject: Re: Platform independend classpath in build.xml? Date: Thu, 1 Jun 2000 18:27:07 +0200 MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit X-Priority: 3 X-MSMail-Priority: Normal X-Mailer: Microsoft Outlook Express +1-220-317-9853 X-MimeOLE: Produced By Microsoft MimeOLE V5.00.2615.200 X-Spam-Rating: locus.apache.org 1.6.2 0/1000/N Hi I am back - sorry for not responding earlier. I did not continue any of my work on Ant as I do not know what the current state is. A month ago we had very interesting discussions on Ant basics. As soon as I know, what the consequences thereof are, I will go on working on Ant. From: Conor MacNeill <dcampbell@example.com> > The PathElement object seems strange to me. It seems to be not so much a > real object, as a set of methods to manipulate the surrounding Path object. > One effect is that the Path object is not composed of PathElement objects, > which I found odd. Another effect is that repeated calls to setLocation on a > PathElement will add multiple File objects to the outer Path object. > Similarly the setPath method adds multiple entries to the Path object, which > again I found a strange thing for a PathElement object. > > If the current structure is to be retained, I think the class and its > methods should be renamed. > > PathElement -> PathManipulator > setLocation -> addLocation > setPath -> addPath. Looking from a design or architectual point of you, I totally agree. The first implementations where closer to what you are suggesting than to what the current code looks like. It has been built that way to cope with the way Ant uses reflection to load and manipulate objects. The way to look at it, is to write down the desired XML code and than create apropriate objects implementing the XML, therefor the things need to be called that way. For the path/file format the list seems to have agreed to use /, \, ;, : and translate them to whatever your platform needs. This is for sure not ideal, but seems to satisfy the needs of most people. - tom From dcampbell@example.com Thu Jun 1 16:41:32 2000 Return-Path: <dcampbell@example.com> Mailing-List: contact dcampbell@example.com; run by ezmlm Delivered-To: mailing list dcampbell@example.com Received: (qmail 53350 invoked from network); 1 Jun 2000 16:41:32 -0000 Received: from mcdc-us-smtp5.cdc.gov (83.161.120.155) by locus.apache.org with SMTP; 1 Jun 2000 16:41:32 -0000 Received: from mcdc-us-tis.cdc.gov (mcdc-us-tisgate.cdc.gov [83.161.120.155]) by mcdc-us-smtp5.cdc.gov with SMTP (Microsoft Exchange Internet Mail Service Version 5.5.2650.21) id MAZ1TYFS; Thu, 1 Jun 2000 12:35:41 -0400 Received: by mcdc-us-tis.cdc.gov with Internet Mail Service (5.5.2650.21) id <MAZV03WK>; Thu, 1 Jun 2000 12:40:57 -0400 Message-ID: <1537895B1173D1118D9300A0246212B60596C328@MCDC-ATL-4> From: "Chaganthi, Madhusudan R." <dcampbell@example.com> To: "'dcampbell@example.com'" <dcampbell@example.com> Subject: RE: PrintWriter deprecated in the 3.1 build Date: Thu, 1 Jun 2000 12:41:00 -0400 MIME-Version: 1.0 X-Mailer: Internet Mail Service (5.5.2650.21) Content-Type: text/plain; charset="iso-8859-1" X-Spam-Rating: locus.apache.org 1.6.2 0/1000/N This is the log output when try to run bootstrap. Is there anything I can do about this?? ____________________________________________________________________ ........... ... Building Ant Distribution java -ms128 -mx128 org.apache.tools.ant.Main main Buildfile: build.xml Project base dir set to: C:\tools\jakarta-ant Executing Target: prepare Created dir: C:\tools\jakarta-ant\build Executing Target: check_for_optional_packages Executing Target: compile Created dir: C:\tools\jakarta-ant\build\classes Compiling 57 source files to C:\tools\jakarta-ant\build\classes C:\tools\jakarta-ant\src\main\org\apache\tools\ant\Main.java:118: Note: The cons tructor java.io.PrintStream(java.io.OutputStream) has been deprecated. out = new PrintStream(new FileOutputStream(logFile)); ^ java.lang.OutOfMemoryError: dcampbell@example.com(Compiled Code) at org.apache.tools.ant.Project.runTarget(Project.java:676) at org.apache.tools.ant.Project.executeTarget(Compiled Code) at org.apache.tools.ant.Main.runBuild(Compiled Code) at org.apache.tools.ant.Main.main(Compiled Code) C:\tools\jakarta-ant\src\main\org\apache\tools\ant\taskdefs\Ant.java:111: Note: The constructor java.io.PrintStream(java.io.OutputStream) has been deprecated. PrintStream out=new PrintStream(new FileOutputStream(output)); ^ error: An error has occurred in the compiler; please file a bug report (http://j ava.sun.com/cgi-bin/bugreport.cgi). Note: 2 files use deprecated APIs. Please consult the documentation for a bette r alternative in each case. 1 error, 3 warnings BUILD FATAL ERROR: Compile failed, messages should have been provided. ... Cleaning Up Build Directories Buildfile: build.xml Project base dir set to: C:\tools\jakarta-ant Executing Target: clean Deleting: C:\tools\jakarta-ant\build Deleting: C:\tools\jakarta-ant\dist Completed in 1 seconds ... Done Bootstrapping Ant Distribution ____________________________________________________________________________ ______ -----Original Message----- From: Chaganthi, Madhusudan R. [mailto:dcampbell@example.com] Sent: Thursday, June 01, 2000 12:06 PM To: 'dcampbell@example.com' Subject: PrintWriter deprecated in the 3.1 build Hi All I have been trying to run bootstrap with the 3.1 build jakarta-ant.zip 18-Apr-2000 16:09 331k I am running into deprecated api (in org.apache.tools.ant.Main) where it uses java.io.PrintStream. Is there a future version which took care of this? I ran into a OutOfMemory at about the same point even after going for -ms128 and -mx128. Any suggestions would be most helpful. Thanks Madhu From dcampbell@example.com Thu Jun 1 16:55:16 2000 Return-Path: <dcampbell@example.com> Mailing-List: contact dcampbell@example.com; run by ezmlm Delivered-To: mailing list dcampbell@example.com Received: (qmail 59475 invoked from network); 1 Jun 2000 16:55:16 -0000 Received: from mcdc-us-smtp3.cdc.gov (83.161.120.155) by locus.apache.org with SMTP; 1 Jun 2000 16:55:16 -0000 Received: from mcdc-us-tis.cdc.gov (mcdc-us-tisgate.cdc.gov [83.161.120.155]) by mcdc-us-smtp3.cdc.gov with SMTP (Microsoft Exchange Internet Mail Service Version 5.5.2651.58) id MC3SRVFG; Thu, 1 Jun 2000 12:54:32 -0400 Received: by mcdc-us-tis.cdc.gov with Internet Mail Service (5.5.2650.21) id <MAZV0P2V>; Thu, 1 Jun 2000 12:54:40 -0400 Message-ID: <1537895B1173D1118D9300A0246212B60596C32A@MCDC-ATL-4> From: "Chaganthi, Madhusudan R." <dcampbell@example.com> To: "'dcampbell@example.com'" <dcampbell@example.com> Subject: RE: PrintWriter deprecated in the 3.1 build Date: Thu, 1 Jun 2000 12:54:44 -0400 MIME-Version: 1.0 X-Mailer: Internet Mail Service (5.5.2650.21) Content-Type: text/plain; charset="iso-8859-1" X-Spam-Rating: locus.apache.org 1.6.2 0/1000/N Hi All Sorry if I am being persistent but ...... I have added 4 new files (to accomodate new tasks) in the appropriate directories. ejbc, ejbcHelper, DDCreator and DDCreatorHelper. If I use the bootstrap with just the 53 files that come with 3.1 build, everything runs fine. Could 4 more files crash the process? Thanks Madhu P.S. Conor, did you run into this problem when you first tried to build with these tasks?? From dcampbell@example.com Thu Jun 1 21:20:48 2000 Return-Path: <dcampbell@example.com> Mailing-List: contact dcampbell@example.com; run by ezmlm Delivered-To: mailing list dcampbell@example.com Received: (qmail 15148 invoked from network); 1 Jun 2000 21:20:48 -0000 Received: from smtp.networkusa.net (dcampbell@example.com) by locus.apache.org with SMTP; 1 Jun 2000 21:20:48 -0000 Received: from zhouserver.geekfarm.org (adsl-100-217.valuenet.net [83.161.120.155]) by smtp.networkusa.net (8.8.7/8.8.7) with ESMTP id QAA02535 for <dcampbell@example.com>; Thu, 1 Jun 2000 16:47:25 -0500 Message-Id: <dcampbell@example.com> X-Sender: dcampbell@example.com X-Mailer: QUALCOMM Windows Eudora Version 4.3 Date: Thu, 01 Jun 2000 15:57:54 -0500 To: dcampbell@example.com From: Erik Meade <dcampbell@example.com> Subject: RE: [PATCH]? Jcvs taskdef In-Reply-To: <dcampbell@example.com> References: <dcampbell@example.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii"; format=flowed X-Spam-Rating: locus.apache.org 1.6.2 0/1000/N Good stuff, let me do this again: I noticed this comment in Cvs taskdef: // XXX: we should use JCVS (www.ice.com/JCVS) instead of command line // execution so that we don't rely on having native CVS stuff around (SM) So took a stab at it and started a optional Jcvs taskdef, which uses Tim's com.ice.cvsc package. ( http://www.gjt.org/servlets/JCVSlet/zip/ice/com/ice/cvsc/cvsc.zip ) I've included a two patchs. One to add the Jcvs taskdef to the defaults.properties. ( as an optional taskdef ). Another to update the build.xml ( to check for the existence of the com.ice.cvsc. classes ) as well as the Jcvs.java file. Jcvs is backwards compatible with Cvs, except for the "-r" option. ( Because I didn't implement it, not because it is unimplementable ). Thanks to Conor and Glen for the feedback! Erik Meade --- build.xml.orig Thu Jun 01 14:58:34 2000 +++ build.xml Thu Jun 01 14:58:14 2000 @@ -37,6 +37,7 @@ <target name="check_for_optional_packages"> <available property="bsf.present" classname="com.ibm.bsf.BSFManager" /> <available property="netrexx.present" classname="netrexx.lang.Rexx" /> + <available property="cvsc.present" classname="com.ice.cvsc.CVSProject" /> </target> <!-- =================================================================== --> @@ -60,6 +61,7 @@ optimize="on" > <exclude name="**/Script.java" unless="bsf.present" /> <exclude name="**/NetRexxC.java" unless="netrexx.present" /> + <exclude name="**/Jcvs.java" unless="cvsc.present" /> </javac> <copydir src="${src.dir}" dest="${build.classes}"> --- defaults.properties.orig Thu Jun 01 00:19:50 2000 +++ defaults.properties Thu Jun 01 14:50:36 2000 @@ -34,6 +34,7 @@ script=org.apache.tools.ant.taskdefs.optional.Script netrexxc=org.apache.tools.ant.taskdefs.optional.NetRexxC renameext=org.apache.tools.ant.taskdefs.optional.RenameExtensions +jcvs=org.apache.tools.ant.taskdefs.Jcvs # deprecated ant tasks (kept for back compatibility) javadoc2=org.apache.tools.ant.taskdefs.Javadoc /* * The Apache Software License, Version 1.1 * * Copyright (c) 1999 The Apache Software Foundation. All rights * reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions * are met: * * 1. Redistributions of source code must retain the above copyright * notice, this list of conditions and the following disclaimer. * * 2. Redistributions in binary form must reproduce the above copyright * notice, this list of conditions and the following disclaimer in * the documentation and/or other materials provided with the * distribution. * * 3. The end-user documentation included with the redistribution, if * any, must include the following acknowlegement: * "This product includes software developed by the * Apache Software Foundation (http://www.apache.org/)." * Alternately, this acknowlegement may appear in the software itself, * if and wherever such third-party acknowlegements normally appear. * * 4. The names "The Jakarta Project", "Tomcat", and "Apache Software * Foundation" must not be used to endorse or promote products derived * from this software without prior written permission. For written * permission, please contact dcampbell@example.com. * * 5. Products derived from this software may not be called "Apache" * nor may "Apache" appear in their names without prior written * permission of the Apache Group. * * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. * ==================================================================== * * This software consists of voluntary contributions made by many * individuals on behalf of the Apache Software Foundation. For more * information on the Apache Software Foundation, please see * <http://www.apache.org/>. */ package org.apache.tools.ant.optional.taskdefs; import com.ice.cvsc.*; import java.io.File; import org.apache.tools.ant.BuildException; import org.apache.tools.ant.taskdefs.Exec; /** * * * @author dcampbell@example.com */ public class Jcvs extends Exec implements CVSUserInterface { String userName; String password = "anoncvs"; String hostName; String repository; String rootDirectory; String localDirectory; String tempDirectory; boolean isPServer = true; int connMethod = CVSRequest.METHOD_INETD; int cvsPort = 2401; public void execute() throws BuildException { if (tempDirectory == null) { tempDirectory = System.getProperty("java.io.tmpdir"); } if (localDirectory == null) { localDirectory = "."; } CVSRequest request = new CVSRequest(); boolean parsed = request.parseControlString(":co:N:ANP:deou:"); CVSEntryVector entries = new CVSEntryVector(); CVSArgumentVector arguments = new CVSArgumentVector(); arguments.appendArgument(repository); CVSClient client = new CVSClient(hostName, cvsPort ); CVSProject project = new CVSProject(client); project.setUserName(userName); project.setTempDirectory(tempDirectory); project.setRepository(repository); project.setRootDirectory(rootDirectory); project.setLocalRootDirectory(localDirectory); project.setPServer(isPServer); project.setConnectionMethod(connMethod); project.setPassword(CVSScramble.scramblePassword( password, 'A' )); project.establishRootEntry(rootDirectory); request.setPServer(isPServer); request.setUserName(userName); request.setPassword(project.getPassword()); request.setConnectionMethod(connMethod); request.setPort(cvsPort); request.setHostName(hostName); request.setRepository(repository); request.setRootDirectory(rootDirectory); request.setRootRepository(rootDirectory); request.setLocalDirectory(localDirectory); request.responseHandler = project; request.traceRequest = CVSProject.overTraceRequest; request.traceResponse = CVSProject.overTraceResponse; request.traceTCPData = CVSProject.overTraceTCP; request.traceProcessing = CVSProject.overTraceProcessing; request.setEntries(entries); request.appendArguments(arguments); request.setUserInterface(this); CVSResponse response = client.processCVSRequest(request); response.deleteTempFiles(); } public void setDest(String dest) { setDir(dest); } public void setHostName(String hostName) { this.hostName = hostName; } public void setLocalDir(String localDir) { this.localDirectory = localDir; } public void setPassword(String password) { this.password = password; } public void setPort(int port) { cvsPort = port; } public void setRepository(String repository) { this.repository = repository; } public void setRootDir(String rootDir) { rootDirectory = rootDir; } public void setTempDir(String tempDir) { tempDirectory = tempDir; } public void setUserName(String userName) { this.userName = userName; } // For backward compatabitly with Cvs. public void setCvsRoot(String root) { // XXX: handle non isPServer if (root.startsWith(":pserver:")) { isPServer = true; // strip off the :pserver: root = root.substring(9); } int atIndex = root.indexOf("@"); int cvsrootIndex = root.indexOf(":"); userName = root.substring(0, atIndex); hostName = root.substring(atIndex + 1, cvsrootIndex); rootDirectory = root.substring(cvsrootIndex + 1); } public void setPackage(String p) { repository = p; } // XXX: Need to handle this in the Jcvs way public void setTag(String p) { // Check if not real tag => set it to null if (p != null) { if (p.trim().equals("")) p = null; } // this.tag = p; } // // CVS USER INTERFACE METHODS // public void uiDisplayProgressMsg( String message ) { project.log( message, "jcvs", project.MSG_VERBOSE ); } public void uiDisplayProgramError( String error ) { project.log( error, "jvcs:error", project.MSG_ERR ); } public void uiDisplayResponse( CVSResponse response ) { } // // END OF CVS USER INTERFACE METHODS // } From dcampbell@example.com Fri Jun 2 01:36:39 2000 Return-Path: <dcampbell@example.com> Mailing-List: contact dcampbell@example.com; run by ezmlm Delivered-To: mailing list dcampbell@example.com Received: (qmail 7805 invoked from network); 2 Jun 2000 01:36:39 -0000 Received: from smtp.thespot.com.au (83.161.120.155) by locus.apache.org with SMTP; 2 Jun 2000 01:36:39 -0000 Received: from monkey.prod.thespot.com.au (monkey.prod.thespot.com.au [83.161.120.155]) by smtp.thespot.com.au (8.9.3/8.9.3) with ESMTP id LAA18947 for <dcampbell@example.com>; Fri, 2 Jun 2000 11:35:41 +1000 (EST) Received: (from daemon@localhost) by monkey.prod.thespot.com.au (8.10.0/8.10.0) id e521aWU06034 for <dcampbell@example.com>; Fri, 2 Jun 2000 11:36:32 +1000 (EST) Received: from snotty.devl.ebinteractive.com.au(83.161.120.155), claiming to be "snotty" via SMTP by monkey, id smtpdAAA1EaGVl; Fri Jun 2 11:36:23 2000 From: "Conor MacNeill" <dcampbell@example.com> To: <dcampbell@example.com> Subject: RE: PrintWriter deprecated in the 3.1 build Date: Fri, 2 Jun 2000 11:37:41 +1000 Message-ID: <dcampbell@example.com> MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit X-Priority: 3 (Normal) X-MSMail-Priority: Normal X-Mailer: Microsoft Outlook IMO, Build 9.0.2416 (9.0.2910.0) Importance: Normal X-MimeOLE: Produced By Microsoft MimeOLE V5.00.2314.1300 In-Reply-To: <1537895B1173D1118D9300A0246212B60596C32A@MCDC-ATL-4> X-Spam-Rating: locus.apache.org 1.6.2 0/1000/N Chaganthi, I genrally have been building with jdk1.2.2 no problems. Nevertheless I have just bootstrapped ant using 1.3. Note that my ant build varies quite a bit from the ant in CVS these days. Here is the result. Conor F:\jakarta\jakarta-ant>bootstrap ... Bootstrapping Ant Distribution JAVA_HOME=f:\jdk1.3 JAVA=f:\jdk1.3\bin\java JAVAC=f:\jdk1.3\bin\javac CLASSPATH=src\main;classes;F:\Jaxp1.0\jaxp.jar;F:\Jaxp1.0\parser.jar;f:\jdk1 .3\lib\tools.jar ... Compiling Ant Classes ... Copying Required Files src\main\org\apache\tools\ant\taskdefs\defaults.properties 1 file(s) copied. ... Building Ant Distribution Buildfile: build.xml Project base dir set to: F:\jakarta\jakarta-ant Executing Target: prepare Created dir: F:\jakarta\build\ant Executing Target: check_for_optional_packages Executing Target: compile Created dir: F:\jakarta\build\ant\classes Unable to open dependency file - ignoring Compiling 81 source files to F:\jakarta\build\ant\classes Copying 4 support files to F:\jakarta\build\ant\classes Executing depend with srcspec = ../build/ant/classes and depfile = ..\build\ant\ant.dep Executing Target: jar Building jar: F:\jakarta\jakarta-ant\lib\ant.jar Executing Target: main Completed in 10 seconds ... Cleaning Up Build Directories Buildfile: build.xml Project base dir set to: F:\jakarta\jakarta-ant Executing Target: clean Deleting: F:\jakarta\build\ant Deleting: F:\jakarta\dist\ant Completed in 0 seconds ... Done Bootstrapping Ant Distribution F:\jakarta\jakarta-ant> -- Conor MacNeill dcampbell@example.com Cortex eBusiness > -----Original Message----- > From: Chaganthi, Madhusudan R. [mailto:dcampbell@example.com] > Sent: Friday, 2 June 2000 2:55 > To: 'dcampbell@example.com' > Subject: RE: PrintWriter deprecated in the 3.1 build > > > Hi All > > Sorry if I am being persistent but ...... > > I have added 4 new files (to accomodate new tasks) in the appropriate > directories. > ejbc, ejbcHelper, DDCreator and DDCreatorHelper. > > If I use the bootstrap with just the 53 files that come with 3.1 build, > everything runs fine. > > Could 4 more files crash the process? > > Thanks > Madhu > > > P.S. Conor, did you run into this problem when you first tried to > build with > these tasks?? > From dcampbell@example.com Fri Jun 2 07:35:32 2000 Return-Path: <dcampbell@example.com> Mailing-List: contact dcampbell@example.com; run by ezmlm Delivered-To: mailing list dcampbell@example.com Received: (qmail 76870 invoked from network); 2 Jun 2000 07:35:32 -0000 Received: from smtp01do.de.uu.net (83.161.120.155) by locus.apache.org with SMTP; 2 Jun 2000 07:35:32 -0000 Received: from sbodewig.bost.de ([83.161.120.155]) by smtp01do.de.uu.net (5.5.5/5.5.5) with ESMTP id JAA08438 for <dcampbell@example.com>; Fri, 2 Jun 2000 09:35:31 +0200 (MET DST) Received: (from bodewig@localhost) by sbodewig.bost.de (8.9.3/8.9.3) id JAA12712; Fri, 2 Jun 2000 09:35:31 +0200 X-Authentication-Warning: sbodewig.bost.de: bodewig set sender to dcampbell@example.com using -f To: dcampbell@example.com Subject: Re: Validating task attributes References: <52E3D1B72806D411B15C00508B121ADD02A9B6@uskc01> From: Stefan Bodewig <dcampbell@example.com> Date: 02 Jun 2000 09:35:31 +0200 In-Reply-To: Craig Cottingham's message of "Wed, 31 May 2000 15:38:46 -0500" Message-ID: <dcampbell@example.com> Lines: 18 User-Agent: Gnus/5.0807 (Gnus v5.8.7) XEmacs/21.1 (Canyonlands) MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Spam-Rating: locus.apache.org 1.6.2 0/1000/N >>>>> "CC" == Craig Cottingham <dcampbell@example.com> writes: CC> When is the appropriate time to validate the values of the CC> attributes for a task: when the attribute is set (I assume this CC> happens at parse time), or when the attribute would be used (for CC> instance, in execute())? First, yes you are right, attributes are set at parse time right now. If you want to throw a BuildException on
{'source': 'Apache Software Foundation Public Mail Archives'}