I'm using Maven 1.1-beta-2. I recently had to upgrade the aspectj plugin to
version 4.0 because I was getting a compile error and needed to use aspectj
1.5.

I've got the standard post-goal hool in my maven.xml file...
    <postGoal name="java:compile">
        <attainGoal name="aspectj"/>
    </postGoal>


If I compile using "maven test" it works fine. However if I use "maven site"
it seems to get stuck in a loop. I've looked at the jelly for the plugin and
it seems to be recursively calling the java:compile goal in the
aspectj:test-compile goal. The piece of code is:
      <j:choose>
        <j:when test="${context.getVariable('maven.aspectj.dest') == null}">
          <j:set var="maven.aspectj.dest" value="${maven.build.dest}"/>
        </j:when>
        <j:otherwise>
                <ant:echo>imo:attaining java:compile goal</ant:echo>
          <attainGoal name="java:compile"/>
                <ant:echo>imo:finished java:compile goal</ant:echo>
          <ant:path id="build.dest" location="${maven.build.dest}"/>
          <maven:addPath id="maven.dependency.classpath"
refid="build.dest"/>
        </j:otherwise>
      </j:choose>

So, it's clear that when building "site", "maven.aspectj.dest" isnt setup. I
tried adding
        maven.aspectj.dest = ${maven.build.dest}
In my project.properties, but it didn't help.

The aspectj related properties I have set are:
        maven.aspectj.source=1.4
        maven.aspectj.lint=ignore
        maven.aspectj.maxmem=512m
        maven.aspectj.fork=true


I include output from "maven test" and "maven site" below.

Any help appreciated,

Regards,
Ian Orford

>>>>>>>>>>>>>> OUTPUT FROM maven test <<<<<<<<<<<<<<<<
----------------------------------------------------------------------------
----
build:start:

java:prepare-filesystem:

java:compile:
    [echo] Compiling to C:\Dev\SVN\ewarningtools\EWT/target/classes
    [echo]
==========================================================

  NOTE: Targetting JVM 1.4, classes
  will not run on earlier JVMs

==========================================================

Running post goal: java:compile
aspectj:init:

aspectj:compile:

aspectj:test-compile:
    [echo] imo1
    [echo] imo:in first if

aspectj:


java:jar-resources:

test:prepare-filesystem:

test:test-resources:

test:compile:

test:test:
<deleted>
----------------------------------------------------------------------------
----



>>>>>>>>>>>>>> OUTPUT FROM maven site <<<<<<<<<<<<<<<<
maven-jdepend-plugin:report:
java:prepare-filesystem:

java:compile:
    [echo] Compiling to C:\Dev\SVN\ewarningtools\EWT/target/classes
    [echo]
==========================================================

  NOTE: Targetting JVM 1.4, classes
  will not run on earlier JVMs

==========================================================

Running post goal: java:compile
aspectj:init:

aspectj:compile:

aspectj:test-compile:
    [echo] imo1
    [echo] imo:in first if

aspectj:



    [echo] Generating the Unit Tests...
junit-report:report:
java:prepare-filesystem:

java:compile:
    [echo] Compiling to C:\Dev\SVN\ewarningtools\EWT/target/classes
    [echo]
==========================================================

  NOTE: Targetting JVM 1.4, classes
  will not run on earlier JVMs

==========================================================

Running post goal: java:compile
aspectj:init:

aspectj:compile:

aspectj:test-compile:
    [echo] imo1
    [echo] imo:in first if
    [echo] imo:attaining java:compile goal
java:prepare-filesystem:

java:compile:
    [echo] Compiling to C:\Dev\SVN\ewarningtools\EWT/target/classes
    [echo]
==========================================================

  NOTE: Targetting JVM 1.4, classes
  will not run on earlier JVMs

==========================================================
<etc - deleted>


--------------------------------------------------------------------------------
The information contained herein is confidential and is intended solely for the
addressee. Access by any other party is unauthorised without the express 
written permission of the sender. If you are not the intended recipient, please 
contact the sender either via the company switchboard on +44 (0)20 7623 8000, or
via e-mail return. If you have received this e-mail in error or wish to read our
e-mail disclaimer statement and monitoring policy, please refer to 
http://www.dresdnerkleinwort.com/disc/email/ or contact the sender. 
--------------------------------------------------------------------------------


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to