You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@ant.apache.org by Diane Holt <ho...@yahoo.com> on 2000/09/16 12:25:56 UTC

Problems running subproject 's

I have a subproject I call from my main build.xml thus:

  <target name="func" depends="demo">
    <ant antfile="functest.xml" dir="${functest.dir}"/>
  </target>

The functest.xml has one target, "functest", which does several <javac>
tasks and a whole bunch of <copyfile>'s. When it does each of the
<javac>'s, it pops up (very briefly -- I'm guessing only while jikes is
actually executing) an empty DOS window (I run on NT under MKS korn
shell). This doesn't happen on the <javac> tasks I run out of build.xml --
only the ones out of functest.xml. Once the target hits the point where
one of the <javac>'s include names has a ** wildcard in it, I get the
following:

    [javac] The following character string is too long:
    [javac]
BUILD FAILED
build.xml:635: Compile failed, messages should have been provided.
Total time: 31 seconds

Any ideas on what could be causing this behaviour? Why the DOS window pop
up's, and the "string too long" error (which I'm assuming is coming from
DOS)?  None of this happens if I run these same <javac>'s from the top
level build.xml file. (But I was hoping not to have to do that, since this
target not only involves a bunch of <javac>'s but also a majillion file
copies, and I was hoping to keep the top-level build.xml relatively
succinct -- as it is, it's 832 lines, and there's still more to come.)

Thanks,
Diane


=====
(holtdl@yahoo.com)



__________________________________________________
Do You Yahoo!?
Yahoo! Mail - Free email you can access from anywhere!
http://mail.yahoo.com/

Re: Problems running subproject 's

Posted by Nico Seessle <ni...@seessle.de>.
As a temporary fix the following may work:

In the method executeJikesCompile in Javac.java change the statement

            if (myos.toLowerCase().indexOf("windows") >= 0
                && (args.length > 250 || winsucks)) {

to read
            if (myos.toLowerCase().indexOf("windows") >= 0) {

Ant will then write all (source-file) arguments to a temporary file and pass
this to the compiler. Don't know why this works from the main-buildfile but
not if called from the outside, but I will have a look at it and maybe we
will find a "real" fix for this...

I have no plan currently how to get rid of the additional DOS-Windows, but
they shouldn't hurt so much :-)

Hope this helps

Nico

----- Original Message -----
From: "Diane Holt" <ho...@yahoo.com>
To: <an...@jakarta.apache.org>
Sent: Saturday, September 16, 2000 12:25 PM
Subject: Problems running subproject <javac>'s


> I have a subproject I call from my main build.xml thus:
>
>   <target name="func" depends="demo">
>     <ant antfile="functest.xml" dir="${functest.dir}"/>
>   </target>
>
> The functest.xml has one target, "functest", which does several <javac>
> tasks and a whole bunch of <copyfile>'s. When it does each of the
> <javac>'s, it pops up (very briefly -- I'm guessing only while jikes is
> actually executing) an empty DOS window (I run on NT under MKS korn
> shell). This doesn't happen on the <javac> tasks I run out of build.xml --
> only the ones out of functest.xml. Once the target hits the point where
> one of the <javac>'s include names has a ** wildcard in it, I get the
> following:
>
>     [javac] The following character string is too long:
>     [javac]
> BUILD FAILED
> build.xml:635: Compile failed, messages should have been provided.
> Total time: 31 seconds
>
> Any ideas on what could be causing this behaviour? Why the DOS window pop
> up's, and the "string too long" error (which I'm assuming is coming from
> DOS)?  None of this happens if I run these same <javac>'s from the top
> level build.xml file. (But I was hoping not to have to do that, since this
> target not only involves a bunch of <javac>'s but also a majillion file
> copies, and I was hoping to keep the top-level build.xml relatively
> succinct -- as it is, it's 832 lines, and there's still more to come.)
>
> Thanks,
> Diane
>
>
> =====
> (holtdl@yahoo.com)
>
>
>
> __________________________________________________
> Do You Yahoo!?
> Yahoo! Mail - Free email you can access from anywhere!
> http://mail.yahoo.com/