- Removed dep on piccolo and jexl as they don't seem to be used
- Added new aspectwerkz:transform goal to weave aspects at build time git-svn-id: https://svn.apache.org/repos/asf/maven/maven-1/plugins/trunk@114507 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
@@ -10,21 +10,40 @@
|
||||
xmlns:j="jelly:core"
|
||||
xmlns:util="jelly:util">
|
||||
|
||||
<!--
|
||||
========================================================================
|
||||
Init.
|
||||
========================================================================
|
||||
-->
|
||||
<goal name="aspectwerkz:init">
|
||||
|
||||
<ant:mkdir dir="${maven.build.dir}"/>
|
||||
|
||||
<path id="classpath.main">
|
||||
<ant:pathelement location="${maven.dependency.classpath}"/>
|
||||
<ant:pathelement location="${plugin.getDependencyPath('aspectwerkz:aspectwerkz')}"/>
|
||||
<ant:pathelement location="${plugin.getDependencyPath('dom4j:dom4j')}"/>
|
||||
<ant:pathelement location="${plugin.getDependencyPath('trove:trove')}"/>
|
||||
</path>
|
||||
|
||||
</goal>
|
||||
|
||||
<!--
|
||||
========================================================================
|
||||
Compile AW javadoc attributes.
|
||||
========================================================================
|
||||
-->
|
||||
<goal name="aspectwerkz:attributec"
|
||||
<goal name="aspectwerkz:attributec" prereqs="aspectwerkz:init"
|
||||
description="Compile AspectWerkz javadoc attributes">
|
||||
|
||||
<ant:mkdir dir="${maven.build.dir}"/>
|
||||
|
||||
<!-- TODO: only run attributeC if sources are newer than target
|
||||
XML definition file -->
|
||||
|
||||
<ant:java dir="${maven.build.dir}" failonerror="true" fork="true"
|
||||
classname="org.codehaus.aspectwerkz.metadata.AttributeC">
|
||||
|
||||
<sysproperty key="aspectwerkz.definition.validate"
|
||||
value="${maven.aspectwerkz.definition.validate}"/>
|
||||
<ant:sysproperty key="aspectwerkz.definition.validate"
|
||||
value="${maven.aspectwerkz.definition.validate}"/>
|
||||
|
||||
<ant:arg file="${maven.aspectwerkz.src.dir}"/>
|
||||
<ant:arg file="${maven.aspectwerkz.build.definition.file}"/>
|
||||
@@ -36,20 +55,59 @@
|
||||
</j:if>
|
||||
|
||||
<ant:classpath>
|
||||
<ant:pathelement location="${maven.dependency.classpath}"/>
|
||||
<ant:pathelement location="${plugin.getDependencyPath('aspectwerkz:aspectwerkz')}"/>
|
||||
<ant:path refid="classpath.main"/>
|
||||
<ant:pathelement location="${plugin.getDependencyPath('qdox:qdox')}"/>
|
||||
<ant:pathelement location="${plugin.getDependencyPath('trove:trove')}"/>
|
||||
<ant:pathelement location="${plugin.getDependencyPath('dom4j:dom4j')}"/>
|
||||
<ant:pathelement location="${plugin.getDependencyPath('jrexx:jrexx')}"/>
|
||||
|
||||
<!-- vmassol: I am not sure whether these 2 jars are required or not -->
|
||||
<ant:pathelement location="${plugin.getDependencyPath('piccolo:piccolo')}"/>
|
||||
<ant:pathelement location="${plugin.getDependencyPath('commons-jexl:commons-jexl')}"/>
|
||||
</ant:classpath>
|
||||
|
||||
</ant:java>
|
||||
|
||||
</goal>
|
||||
|
||||
<!--
|
||||
========================================================================
|
||||
Tranform source code by weaving aspects to them (offline mode).
|
||||
========================================================================
|
||||
-->
|
||||
<goal name="aspectwerkz:transform"
|
||||
prereqs="aspectwerkz:init,aspectwerkz:attributec,java:compile"
|
||||
description="Weave aspects to sources (offline mode)">
|
||||
|
||||
<!-- TODO: Add support for extension classes -->
|
||||
|
||||
<ant:java dir="${maven.build.dir}" failonerror="true" fork="true"
|
||||
classname="org.codehaus.aspectwerkz.compiler.AspectWerkzC">
|
||||
|
||||
<ant:sysproperty key="aspectwerkz.transform.filter"
|
||||
value="${maven.aspectwerkz.transform.filter}"/>
|
||||
<ant:sysproperty key="aspectwerkz.definition.file"
|
||||
value="${maven.aspectwerkz.definition.file}"/>
|
||||
|
||||
<ant:arg value="-verify"/>
|
||||
<ant:arg file="${maven.build.dest}"/>
|
||||
|
||||
<ant:classpath>
|
||||
<ant:path refid="classpath.main"/>
|
||||
<ant:pathelement location="${plugin.getDependencyPath('ant:ant')}"/>
|
||||
<ant:pathelement location="${plugin.getDependencyPath('aspectwerkz:aspectwerkz-core')}"/>
|
||||
<ant:pathelement location="${plugin.getDependencyPath('bcel:bcel')}"/>
|
||||
</ant:classpath>
|
||||
<!--
|
||||
set ASPECTWERKZ_LIBS=%ASPECTWERKZ_HOME%\lib\dom4j-1.4.jar;%ASPECTWERKZ_HOME%\lib\qdox-1.3.jar;%ASPECTWERKZ_HOME%\lib\concurrent-1.3.1.jar;%ASPECTWERKZ_HOME%\lib\trove-1.0.2.jar;%ASPECTWERKZ_HOME%\lib\commons-jexl-1.0-beta-2.jar;%ASPECTWERKZ_HOME%\lib\piccolo-1.03.jar;%ASPECTWERKZ_HOME%\lib\jrexx-1.1.1.jar
|
||||
|
||||
"%JAVA_COMMAND%"
|
||||
-Daspectwerkz.transform.filter=no
|
||||
-Daspectwerkz.definition.file=${basedir}/src/samples/aspectwerkz.xml
|
||||
-Daspectwerkz.home=%ASPECTWERKZ_HOME%
|
||||
-cp "%ASPECTWERKZ_HOME%\lib\ant-1.5.2.jar;%ASPECTWERKZ_HOME%\lib\aspectwerkz-core-%ASPECTWERKZ_VERSION%.jar;%ASPECTWERKZ_HOME%\lib\aspectwerkz-%ASPECTWERKZ_VERSION%.jar;%ASPECTWERKZ_LIBS%;%ASPECTWERKZ_HOME%\lib\bcel-patch.jar;%ASPECTWERKZ_HOME%\lib\bcel.jar"
|
||||
"org.codehaus.aspectwerkz.compiler.AspectWerkzC"
|
||||
-verify
|
||||
-cp ${extensions.classes}
|
||||
${samples.classes}
|
||||
-->
|
||||
|
||||
</ant:java>
|
||||
|
||||
</goal>
|
||||
|
||||
</project>
|
||||
|
||||
@@ -8,6 +8,10 @@ maven.aspectwerkz.build.definition.file = ${maven.build.dir}/aspectwerkz.xml
|
||||
# Decide whether definition validation is turned on or off.
|
||||
maven.aspectwerkz.definition.validate = false
|
||||
|
||||
maven.aspectwerkz.definition.file = ${maven.aspectwerkz.build.definition.file}
|
||||
|
||||
maven.aspectwerkz.transform.filter = no
|
||||
|
||||
# (optional). Definition file to be merged with the main definition file.
|
||||
# Used by the <aspectwerkz:attributeC> goal.
|
||||
# maven.aspectwerkz.definition.merge.file =
|
||||
|
||||
@@ -36,6 +36,7 @@
|
||||
</developer>
|
||||
</developers>
|
||||
<dependencies>
|
||||
|
||||
<dependency>
|
||||
<groupId>aspectwerkz</groupId>
|
||||
<artifactId>aspectwerkz-core</artifactId>
|
||||
@@ -46,36 +47,45 @@
|
||||
<artifactId>aspectwerkz</artifactId>
|
||||
<version>0.9.RC1</version>
|
||||
</dependency>
|
||||
|
||||
<!-- Required for Attribute compilation -->
|
||||
|
||||
<dependency>
|
||||
<groupId>qdox</groupId>
|
||||
<artifactId>qdox</artifactId>
|
||||
<version>1.3</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>trove</groupId>
|
||||
<artifactId>trove</artifactId>
|
||||
<version>1.0.2</version>
|
||||
<groupId>jrexx</groupId>
|
||||
<artifactId>jrexx</artifactId>
|
||||
<version>1.1.1</version>
|
||||
</dependency>
|
||||
|
||||
<!-- Required for AspectWerkz offline compilation -->
|
||||
|
||||
<dependency>
|
||||
<groupId>ant</groupId>
|
||||
<artifactId>ant</artifactId>
|
||||
<version>1.5.2</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>bcel</groupId>
|
||||
<artifactId>bcel</artifactId>
|
||||
<version>5.1</version>
|
||||
</dependency>
|
||||
|
||||
<!-- Required both for Attribute and AspectWerkz compilations -->
|
||||
<dependency>
|
||||
<groupId>dom4j</groupId>
|
||||
<artifactId>dom4j</artifactId>
|
||||
<version>1.4</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>jrexx</groupId>
|
||||
<artifactId>jrexx</artifactId>
|
||||
<version>1.1.1</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>piccolo</groupId>
|
||||
<artifactId>piccolo</artifactId>
|
||||
<version>1.0.3</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>commons-jexl</groupId>
|
||||
<artifactId>commons-jexl</artifactId>
|
||||
<version>1.0-beta-2</version>
|
||||
<groupId>trove</groupId>
|
||||
<artifactId>trove</artifactId>
|
||||
<version>1.0.2</version>
|
||||
</dependency>
|
||||
|
||||
</dependencies>
|
||||
<reports>
|
||||
<report>maven-changes-plugin</report>
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
|
||||
<goal name="testPlugin">
|
||||
<attainGoal name="clean"/>
|
||||
<attainGoal name="aspectwerkz:attributec"/>
|
||||
<attainGoal name="aspectwerkz:transform"/>
|
||||
</goal>
|
||||
|
||||
</project>
|
||||
@@ -33,6 +33,13 @@
|
||||
</roles>
|
||||
</developer>
|
||||
</developers>
|
||||
<dependencies>
|
||||
<dependency>
|
||||
<groupId>aspectwerkz</groupId>
|
||||
<artifactId>aspectwerkz</artifactId>
|
||||
<version>0.9.RC1</version>
|
||||
</dependency>
|
||||
</dependencies>
|
||||
<build>
|
||||
<sourceDirectory>src/main</sourceDirectory>
|
||||
</build>
|
||||
|
||||
@@ -13,6 +13,12 @@
|
||||
Compile AspectWerkz javadoc attributes.
|
||||
</description>
|
||||
</goal>
|
||||
<goal>
|
||||
<name>aspectwerkz:transform</name>
|
||||
<description>
|
||||
Weaves aspects on byte code (offline mode).
|
||||
</description>
|
||||
</goal>
|
||||
</goals>
|
||||
</body>
|
||||
</document>
|
||||
Reference in New Issue
Block a user