maven-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "pkernevez (JIRA)" <j...@codehaus.org>
Subject [jira] Created: (MCOMPILER-90) Classifier doesn't load the good jar when use with reactor
Date Mon, 05 Jan 2009 16:06:19 GMT
Classifier doesn't load the good jar when use with reactor
----------------------------------------------------------

                 Key: MCOMPILER-90
                 URL: http://jira.codehaus.org/browse/MCOMPILER-90
             Project: Maven 2.x Compiler Plugin
          Issue Type: Bug
    Affects Versions: 2.0.2
            Reporter: pkernevez


I have a project named _common_ that is build with the goal   _test-jar_ for making a jar
with the test classe.
It produce :
* one jar with only the _main_ classes (common-2.0.jar)
* one jat with only the tests classes (common-2.0-tests.jar)

I have another project (named _tests_ that need the _test_ for building its main classes.

So I had this dependencies to its pom as I need both _main_ and _test_ classes: 
{code}
        <dependency>
            <groupId>com.octo.opensource.jmonitoring</groupId>
            <artifactId>common</artifactId>
            <version>2.0-SNAPSHOT</version>
            <classifier>tests</classifier>
        </dependency>

        <dependency>
            <groupId>com.octo.opensource.jmonitoring</groupId>
            <artifactId>common</artifactId>
            <version>2.0-SNAPSHOT</version>
        </dependency>
{code}

When I run only my _tests_ project, there is no problem, according to that the plugin use
this classe path:
{code}
[DEBUG] Output directory: C:\dev\JMonitoring\framework\tests\target\test-classes
[DEBUG] Classpath:
[DEBUG]  C:\dev\JMonitoring\framework\tests\target\test-classes
[DEBUG]  C:\dev\JMonitoring\framework\tests\target\classes
[DEBUG]  C:\local-repo\junit\junit\4.4\junit-4.4.jar
[DEBUG]  C:\local-repo\com\octo\opensource\jmonitoring\common\2.0-SNAPSHOT\common-2.0-SNAPSHOT-tests.jar
[DEBUG]  C:\local-repo\com\octo\opensource\jmonitoring\common\2.0-SNAPSHOT\common-2.0-SNAPSHOT.jar
{code}

But when I run it in the reactor with the _common_ project I have 2 times the same jar
{code}
[DEBUG] Output directory: C:\dev\JMonitoring\framework\tests\target\classes
[DEBUG] Classpath:
[DEBUG]  C:\dev\JMonitoring\framework\tests\target\classes
[DEBUG]  C:\local-repo\junit\junit\4.4\junit-4.4.jar
[DEBUG]  C:\local-repo\com\octo\opensource\jmonitoring\common\2.0-SNAPSHOT\common-2.0-SNAPSHOT-tests.jar
[DEBUG]  C:\local-repo\com\octo\opensource\jmonitoring\common\2.0-SNAPSHOT\common-2.0-SNAPSHOT.jar
{code}

And my build fail during the compilation.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

Mime
View raw message