ant-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From bode...@apache.org
Subject cvs commit: jakarta-ant/src/main/org/apache/tools/ant/taskdefs Javadoc.java
Date Thu, 13 Jun 2002 12:40:18 GMT
bodewig     2002/06/13 05:40:18

  Modified:    src/main/org/apache/tools/ant/taskdefs Tag: ANT_15_BRANCH
                        Javadoc.java
  Log:
  Don't add -xxxpath if the corresponding path is empty in <javadoc>.
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.96.2.5  +11 -7     jakarta-ant/src/main/org/apache/tools/ant/taskdefs/Javadoc.java
  
  Index: Javadoc.java
  ===================================================================
  RCS file: /home/cvs/jakarta-ant/src/main/org/apache/tools/ant/taskdefs/Javadoc.java,v
  retrieving revision 1.96.2.4
  retrieving revision 1.96.2.5
  diff -u -r1.96.2.4 -r1.96.2.5
  --- Javadoc.java	14 May 2002 13:45:12 -0000	1.96.2.4
  +++ Javadoc.java	13 Jun 2002 12:40:18 -0000	1.96.2.5
  @@ -1489,16 +1489,20 @@
           }
   
           if (!javadoc1) {
  -            toExecute.createArgument().setValue("-classpath");
  -            toExecute.createArgument().setPath(classpath);
  +            if (classpath.size() > 0) {
  +                toExecute.createArgument().setValue("-classpath");
  +                toExecute.createArgument().setPath(classpath);
  +            }
               if (sourceDirs.size() > 0) {
                   toExecute.createArgument().setValue("-sourcepath");
                   toExecute.createArgument().setPath(sourceDirs);
               }
           } else {
               sourceDirs.append(classpath);
  -            toExecute.createArgument().setValue("-classpath");
  -            toExecute.createArgument().setPath(sourceDirs);
  +            if (sourceDirs.size() > 0) {
  +                toExecute.createArgument().setValue("-classpath");
  +                toExecute.createArgument().setPath(sourceDirs);
  +            }
           }
   
           if (version && doclet == null) {
  @@ -1549,7 +1553,7 @@
                       }
                   }
               }
  -            if (bootclasspath != null) {
  +            if (bootclasspath != null && bootclasspath.size() > 0) {
                   toExecute.createArgument().setValue("-bootclasspath");
                   toExecute.createArgument().setPath(bootclasspath);
               }
  @@ -1586,9 +1590,9 @@
                                   + " must be provided because the link is "
                                   + "offline");
                           }
  -                        File packageList = 
  +                        File packageListFile = 
                               new File(packageListLocation, "package-list");
  -                        if (packageList.exists()) {
  +                        if (packageListFile.exists()) {
                               toExecute.createArgument().setValue("-linkoffline");
                               toExecute.createArgument().setValue(la.getHref());
                               toExecute.createArgument()
  
  
  

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


Mime
View raw message