diff -wur apache-ant-1.6.5/docs/manual/CoreTasks/rmic.html apache-ant-1.6.5-submit/docs/manual/CoreTasks/rmic.html --- apache-ant-1.6.5/docs/manual/CoreTasks/rmic.html 2005-06-02 15:19:46.000000000 -0500 +++ apache-ant-1.6.5-submit/docs/manual/CoreTasks/rmic.html 2005-08-17 13:35:59.005414800 -0500 @@ -90,6 +90,12 @@ No + includesBase + the parent location to search from when using includes, excludes, etc. + Defaults to the value of the base property. + No + + includes comma- or space-separated list of patterns of files that must be included. All files are included when omitted. diff -wur apache-ant-1.6.5/src/main/org/apache/tools/ant/taskdefs/Rmic.java apache-ant-1.6.5-submit/src/main/org/apache/tools/ant/taskdefs/Rmic.java --- apache-ant-1.6.5/src/main/org/apache/tools/ant/taskdefs/Rmic.java 2005-06-02 15:19:58.000000000 -0500 +++ apache-ant-1.6.5-submit/src/main/org/apache/tools/ant/taskdefs/Rmic.java 2005-08-17 13:27:36.442743000 -0500 @@ -83,6 +83,7 @@ = "Rmic failed; see the compiler error output for details."; private File baseDir; + private File includesBaseDir; private String classname; private File sourceBase; private String stubVersion; @@ -137,6 +138,23 @@ } /** + * Sets the location to search for class files to rmic against; + * optional + * @param includesBase the location to search for class files for rmic to create code for + */ + public void setIncludesBase(File includesBase) { + this.includesBaseDir = includesBase; + } + + /** + * Gets the location to search for class files to rmic against. + * @return the location to search for class files for rmic to create code for + */ + public File getIncludesBase() { + return this.includesBaseDir; + } + + /** * Sets the class to run rmic against; * optional * @param classname the name of the class for rmic to create code for @@ -507,7 +525,12 @@ // scan base dirs to build up compile lists only if a // specific classname is not given if (classname == null) { - DirectoryScanner ds = this.getDirectoryScanner(baseDir); + File scanBase = getIncludesBase(); + if (scanBase == null) { + scanBase = getBase(); + } + + DirectoryScanner ds = this.getDirectoryScanner(scanBase); String[] files = ds.getIncludedFiles(); scanDir(baseDir, files, adapter.getMapper()); } else { diff -wur apache-ant-1.6.5/src/main/org/apache/tools/ant/taskdefs/rmic/DefaultRmicAdapter.java apache-ant-1.6.5-submit/src/main/org/apache/tools/ant/taskdefs/rmic/DefaultRmicAdapter.java --- apache-ant-1.6.5/src/main/org/apache/tools/ant/taskdefs/rmic/DefaultRmicAdapter.java 2005-06-02 15:20:06.000000000 -0500 +++ apache-ant-1.6.5-submit/src/main/org/apache/tools/ant/taskdefs/rmic/DefaultRmicAdapter.java 2005-08-17 13:30:15.694912200 -0500 @@ -96,6 +96,14 @@ */ protected Path getCompileClasspath() { Path classpath = new Path(attributes.getProject()); + + if (attributes.getIncludesBase() != null) { + // having searched for class files here, also add the + // location to the classpath so the internals of rmic + // can "find the classes" from the files. + classpath.setLocation(attributes.getIncludesBase()); + } + // add dest dir to classpath so that previously compiled and // untouched classes are on classpath classpath.setLocation(attributes.getBase());