ant-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Dirk Weigenand <>
Subject Re: [PATCH] - Problems running javac on Windows
Date Tue, 19 Sep 2000 08:14:28 GMT

Stefan Bodewig wrote:
> >>>>> "DW" == Dirk Weigenand <> writes:
>  DW> I haven't looked into the issue very deeply but my feeling is
>  DW> that doJikesCompile should be extended to check the length of the
>  DW> resulting command line and if it exceeds some limit to take the
>  DW> same approach as on Windows XX
> Probably, yes.
> For Linux there is a limit in /usr/include/linux/limits.h:
> #define ARG_MAX       131072    /* # bytes of args + environ for exec() */
> (Kernel 2.2).
> I think POSIX defines a limit for the length of command lines but
> can't remember the details.
> If 1000 files get Jikes into trouble than the filenames must be quite
> long I guess - or carry around a huge environment. Any idea what we
> should take as a limit? 100kByte?
> As for the related problem on Win98 - I'd like to investigate this one
> further before we create temporary files for each and every Jikes
> compile on earth.
> Usually we don't get into trouble with the length of the command
> line. Diane, are you using a very deep directory structure so that the
> filenames themselves get very long?

Under Linux the filenames get indeed very long since the directory where
the project is situated sits rather deep in the directory structure, i.e.
each java source gets prefixed with

So the approach could be to cut this prefix off the filename and use a
filename to shorten the overall command line.


> Maybe we could fix both problems with a single patch, something like
> "if running on Windows and the number of files is > 250 or the total
> command line is longer than (as DOS systems are involved) 64k" to
> trigger the temporary file approach?

Is it really necessary to bind the trigger to the number of arguments rahter
to the combined length of them? I think the problem is bound to the size of
environment and not to the number of arguments (at least not directly since it
should be bounded by the size of the environment anyway?).

> Stefan

Daddy, what does "format disk c: complete" mean?
Who is General Failure and why is he reading my disk?
View raw message