ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
Subject Still having problems with javac source file location
Date Wed, 07 Nov 2001 15:18:51 GMT
I've asked about this before, but I've tried a few more things, and
gathered some more info, so here I go again! I'm still having problems
getting the javac task to correctly find the desired source files, match
them up against the correct target files, and build only whats needed.
Based on reading the documentation and the FAQ on the website( specifically
the bit about always recompiling files that Peter Donald mentioned ) here's
what I've tried:

Directory structure:

In source\com\dstsystems\awd\util I have a source file,  When it
gets compiled, I want the .class file to be in
classes\com\dstsystems\awd\util. Given that, here's how I coded the javac
      destdir="d:\netserver\classes" >
    <include name="com\dstsystems\awd\util\*.java"  />

I've tried running ant with this both from d:\netserver\source and d:
\netserver\source\com\dstsystems\awd\util.  Both times I get the same
result.  Nothing gets built.There are 40 .java files in the util directory,
and none of the class files get built.  I set the javac task up this way
based on a note at the bottom of the Javac task documentation that said

    If you wish to compile only source-files located in some packages below
    a common root you should not include these packages in the
    srcdir-attribute. Use include/exclude-attributes or elements to filter
    for these packages. If you include part of your package-structure
    inside the srcdir-attribute (or nested src-elements) Ant will start to
    recompile your sources every time you call it.

The result I get when I run ant( with -debug ) is the following message:

     FileSet: Setup file scanner in dir D:\netserver\source with patternSet
     { includes: [com\dstsystems\awd\util\*.java] excludes: [] }

Which seems to indicate that what I've done should have javac looking in
the correct directory.  But no files get compiled.

Sorry about detailing the trivia, but this is driving me nuts. I'm sure
I've screwed up something up, and its most likely a little thing that I
wouldn't even consider so I don't want to leave anything out.

To unsubscribe, e-mail:   <>
For additional commands, e-mail: <>

View raw message