1
votes

I want to create a fileset that contains the jdk classpath. The problem is that fileset is composed with files in all of the filesystem, not in a specific directory.
For example:

jdk.classpath.includes = ${jdk.home}/lib/**/*.jar, \
                         ${jdk.home}/../Classes/**/*.jar, \
                         /Library/Java/Extensions/**/*.jar, \
                         /System/Library/Java/Support/Deploy.bundle/Contents/Resources/Java/**/*.jar

So, when i create the fileset i need to do not specify the dir, or to specify the filesystem root directory, like:

<fileset dir="INeedFileSystemRootDirectory" includes="${jdk.classpath.includes}"/>

How can this be accomplished? (I didn't find a built-in property to get the filesystem root)

Thanks.

1

1 Answers

2
votes

You can make your fileset be composed of many tags, each with a different path:

example:

  <fileset dir="${INeedFileSystemRootDirectory}">
    <include name="${jdk.home}/lib/**/*.jar"/>
    <include name="${jdk.home}/../Classes/**/*.jar"/>
     ...
  </fileset>

Documentation and more examples here.