buildr-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Assaf Arkin" <>
Subject Re: javac's -cp flag (a buildr compilation bug?)
Date Wed, 05 Mar 2008 18:42:19 GMT
On 3/5/08, Caleb Powell <> wrote:
> Hi,
> I was using buildr (1.2.1) to compile code in an existing Maven project.
> The
> compile task failed because the Java compiler (Sun JDK1.4.2_13 on Windows)
> does not accept the
> '-cp' alias. From what I can tell, the '-cp' alias was not introduced
> until
> the 1.5 compiler. Here was the output where JAVA_HOME was set to the Sun
> 1.4.2_13 JDK;
> Compiling 403 source files in pharmacy-core:compile
> javac: invalid flag: -cp
> Usage: javac <options> <source files>
> where possible options include:
>   -g                        Generate all debugging info
>   -g:none                   Generate no debugging info
>   -g:{lines,vars,source}    Generate only some debugging info
>   -nowarn                   Generate no warnings
>   -verbose                  Output messages about what the compiler is
> doing
>   -deprecation              Output source locations where deprecated APIs
> are used
>   -classpath <path>         Specify where to find user class files
>   -sourcepath <path>        Specify where to find input source files
>   -bootclasspath <path>     Override location of bootstrap class files
>   -extdirs <dirs>           Override location of installed extensions
>   -d <directory>            Specify where to place generated class files
>   -encoding <encoding>      Specify character encoding used by source
> files
>   -source <release>         Provide source compatibility with specified
> release
>   -target <release>         Generate class files for specific VM version
>   -help                     Print a synopsis of standard options
> rake aborted!
> Assuming that buildr should be compatible with the 1.4.x JDK's (is this
> assumption wrong), than I think this qualifies as a bug (which could be
> easily addressed by using 'classpath').
> In the meantime, is there any workaround to this issue (short of using the
> 1.5 JDK)?
> Cheers!

Newer versions of Buildr invoke the Java compiler through RJB, so they're
not affected but this and also run the build substantially faster.


> Caleb
> "I do not know which makes a man more conservative—to know nothing but the
> present, or nothing but the past."
>   - John Maynard Keynes

  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message