commons-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Jörg Schaible <Joerg.Schai...@scalaris.com>
Subject RE: [CLI] Building Commons CLI
Date Fri, 17 Oct 2008 13:48:16 GMT
Hi Hendrik,

Hendrik Maryns wrote:
> Hi,
> 
> I have downloaded and edited Commons CLI.  It works fine after some
> configuring in Eclipse.  Building from the command line,
> however, fails,
> both with Ant and with Maven.
> 
> Ok, that is not entirely true: ant dist works in that it
> produces a jar,
> but:
> junit-present:
>      [echo] ================================= WARNING
> ================================
>      [echo] Junit isn't present in your ${ANT_HOME}/lib
> directory. Tests
> not executed.
>      [echo]
> ==============================================================
> ============ 
> 
> I tried putting junit.jar into /usr/share/ant/lib, but it still gives
> this error.  What can I do to get it to do the tests?
> 
> Maven is more problematic.  The README says to do mvn jar:jar.  

Really? Either call with Maven 1 "maven jar:jar" or with Maven 2 "mvn install". But maybe
it's time to get rid of M1 entirely as supported build system.

> Well,
> this has failed with a lot of different messages, the latest one is:
> 
>> mvn jar:jar
> [INFO] Scanning for projects...
> [INFO] Searching repository for plugin with prefix: 'jar'. [INFO]
> --------------------------------------------------------------
> ----------
> [INFO] Building Commons CLI
> [INFO]    task-segment: [jar:jar]
> [INFO]
> --------------------------------------------------------------
> ----------
> [INFO] [jar:jar]
> [INFO]
> --------------------------------------------------------------
> ----------
> [ERROR] BUILD ERROR
> [INFO]
> --------------------------------------------------------------
> ----------
> [INFO] Error assembling JAR
> 
> Embedded error: Manifest file: /home/hendrik/workspace/Jakarta
> CLI/target/osgi/MANIFEST.MF does not exist.
> [INFO]
> --------------------------------------------------------------
> ----------
> [INFO] For more information, run Maven with the -e switch [INFO]
> --------------------------------------------------------------
> ----------
> [INFO] Total time: 2 seconds
> [INFO] Finished at: Fri Oct 17 15:33:50 CEST 2008
> [INFO] Final Memory: 10M/151M
> [INFO]
> --------------------------------------------------------------
> ----------
> 
> If I try to do the default mvn clean install it starts out fine, but
> complains about generics, which is obvious, because it gives javac
> the switch -source 1.3!! 

This is the default for Maven. You have to configure the compiler (and javadoc) plugin to
use 1.5 as source and target. We might add this in an profile of the parent POM that is activated
if JDK 5 is used.

> Since I generified CLI, obviously I want to use -source 1.5 (and
> actually, for now, I wouldn't bother with -source at all and get it
> compiling under the latest Java).
> 
> Some recommendations mostly welcome.  Once the tests run, I can start
> submitting patches. 
> 
> H.

- Jörg

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@commons.apache.org
For additional commands, e-mail: dev-help@commons.apache.org


Mime
View raw message