ant-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From bugzi...@apache.org
Subject DO NOT REPLY [Bug 26765] - "-f" option works incorrectly if path includes "../"
Date Fri, 13 Feb 2004 01:00:40 GMT
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG 
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://nagoya.apache.org/bugzilla/show_bug.cgi?id=26765>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND 
INSERTED IN THE BUG DATABASE.

http://nagoya.apache.org/bugzilla/show_bug.cgi?id=26765

"-f" option works incorrectly if path includes "../"





------- Additional Comments From ian@iosphere.net  2004-02-13 01:00 -------
Build files have been modified since last report.  I have appended a copy 
of the file that produced the following result: 
 
ian@ian:~/j/src/ca/gorman/xml 
>ls ../build.xml 
../build.xml 
ian@ian:~/j/src/ca/gorman/xml 
>ant ../build.xml clean 
Buildfile: build.xml does not exist! 
Build failed 
ian@ian:~/j/src/ca/gorman/xml 
> 
 
======= build file ===================================== 
<!-- 
    $Id: build.xml,v 1.1 2004/02/10 20:32:55 ian Exp $ 
 
    "ant" build file for  GXPARSE 
 
    This file is part of GXPARSE, a general XML parser API. 
    Copyright (C) 2003, 2004  Ian E. Gorman 
 
    This program is free software; you can redistribute it and/or modify 
    it under the terms of the GNU General Public License as published by 
    the Free Software Foundation; either version 2 of the License, or 
    (at your option) any later version. 
 
    This program is distributed in the hope that it will be useful, 
    but WITHOUT ANY WARRANTY; without even the implied warranty of 
    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the 
    GNU General Public License for more details. 
     
    You should have received a copy of the GNU General Public License 
    along with this program; if not, write to the Free Software 
    Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA 
    or go to http://www.gnu.org/ 
--> 
 
<!-- 
    Build package ca.gorman.xml.parse and subpackages 
    This file should be in the same directory as the Java source files, 
    but can be run from any directory. 
 
    Targets that can be used from command line 
 
        clean       remove all generated files and directories 
        compile     compile to classes to test directories 
        javadoc     generate javadoc for end user 
        javadoc_all generate javadoc for developer 
        ship        pack for shipping to end user 
        setup       create all destination directories 
 
    Targets that should not be used from command line 
 
        init 
 
    Ian E. Gorman 
   
--> 
 
<project name="build_all" 
         default="default" 
         basedir="./../.."> 
 
  <property name="xml.parse.build.file" 
            value="${basedir}/ca/gorman/xml/parse/build.xml" 
            description="xml parse build file"/> 
  <property name="io.build.file" 
            value="${basedir}/ca/gorman/io/build.xml" 
            description="io build file"/> 
 
  <target name="init"> 
      <tstamp/> 
  </target> 
 
  <target name="default" 
          description="Command line help"> 
    <echo>Build package ${package.name}</echo> 
    <echo>Use "-projecthelp" option to get a list of targets</echo> 
    <echo>Additional info in file comments</echo> 
  </target> 
 
  <!-- define destination directories --> 
  <property name="source.dir" 
            value="${basedir}" 
            description="java source base directory"/> 
  <property name="lib.dir" 
            value="${basedir}/../lib" 
            description="library base directory" /> 
  <property name="class.dir" 
            value="${basedir}/../cls" 
            description="class base directory" /> 
  <property name="doc.dir" 
            value="${basedir}/../doc" 
            description="javadoc base directory"/> 
  <property name="ship.dir" 
            value="${basedir}/../ship" 
            description="staging and shipping directory"/> 
  <property name="doc.ship.dir" 
            value="${ship.dir}/doc" 
            description="staging and shipping directory"/> 
  <property name="lib.ship.dir" 
            value="${ship.dir}/lib" 
            description="staging and shipping directory"/> 
  <property name="src.ship.dir" 
            value="${ship.dir}/src" 
            description="staging and shipping directory"/> 
 
  <!-- create destination directories --> 
  <target name="setup" 
          depends="init" 
          description="Create target directories"> 
    <mkdir dir="${class.dir}"/> 
    <mkdir dir="${doc.dir}"/> 
    <mkdir dir="${lib.dir}"/> 
    <mkdir dir="${ship.dir}"/> 
  </target> 
 
  <!-- remove destination directories and generated files --> 
  <target name="clean" 
          description="Remove targets"> 
    <ant antfile="${io.build.file}" 
         target="clean" 
         inheritall="true" 
         description="package ca.gorman.io"/> 
    <ant antfile="${xml.parse.build.file}" 
         target="clean" 
         inheritall="false" 
         description="package ca.gorman.xml.parse"/> 
  </target> 
 
  <!-- compile --> 
  <target name="compile" 
          depends="setup" 
          description="Compile source files to classes"> 
    <ant antfile="${io.build.file}" 
         target="compile" 
         inheritall="false" 
         description="package ca.gorman.io"/> 
    <ant antfile="${xml.parse.build.file}" 
         target="compile" 
         inheritall="false" 
         description="package ca.gorman.xml.parse"/> 
  </target> 
 
  <!-- build --> 
  <target name="build" 
          depends="clean, compile" 
          description="clean, then compile source files to classes"/> 
 
  <!-- document --> 
  <target name="javadoc" 
          depends="build" 
          description="Build, then create javadoc for end user"> 
    <javadoc classpath="${class.dir}" 
             author="false" 
             private="false" 
             additionalparam="-source 1.4 -quiet" 
             destdir="${doc.dir}"> 
      <link href="http://java.sun.com/j2se/1.4.2/docs/api/"/> 
      <package name="ca.gorman.io.*"/> 
      <package name="ca.gorman.xml.parse.*"/> 
      <sourcepath location="${source.dir}"/> 
      <classpath location="${class.dir}"/> 
    </javadoc> 
  </target> 
 
  <!-- document --> 
  <target name="javadoc_all" 
          depends="build" 
          description="Build, then create javadoc with all information"> 
    <javadoc classpath="${class.dir}" 
             author="true" 
             private="true" 
             additionalparam="-source 1.4 -quiet" 
             destdir="${doc.dir}"> 
      <link href="http://java.sun.com/j2se/1.4.2/docs/api/"/> 
      <package name="ca.gorman.io.*"/> 
      <package name="ca.gorman.xml.parse.*"/> 
      <sourcepath location="${source.dir}"/> 
      <classpath location="${class.dir}"/> 
    </javadoc> 
    <copy description="Supplementary files for ca.gorman" 
          todir="${doc.dir}/ca/gorman/doc-files"> 
      <fileset dir="${source.dir}/ca/gorman/doc-files"/> 
    </copy> 
  </target> 
 
  <target name="shipdoc" 
          depends="javadoc"> 
          <!-- description="Prepare to ship docs"--> 
    <delete dir="${doc.ship.dir}" 
            failonerror="false"/> 
    <mkdir dir="${doc.ship.dir}"/> 
    <copy todir="${doc.ship.dir}" 
          preservelastmodified="true"> 
      <fileset dir="${doc.dir}"/> 
    </copy> 
  </target> 
 
  <target name="ship" 
          depends="shipdoc" 
          description="Pack for shipment to end user"> 
  </target> 
 
</project> 
====================================================================

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@ant.apache.org
For additional commands, e-mail: dev-help@ant.apache.org


Mime
View raw message