diff options
author | Evgeny Mandrikov <Godin@users.noreply.github.com> | 2017-04-24 09:13:21 +0200 |
---|---|---|
committer | Marc R. Hoffmann <hoffmann@mountainminds.com> | 2017-04-24 09:13:21 +0200 |
commit | 30bc8e190e9a90fc43f5f68c499062cd58db3ebe (patch) | |
tree | 39acc1878807f631512826a71da91d6ba83a086a | |
parent | e93053e8a54540f5394fe0938752f7421e2222ad (diff) | |
download | jacoco-30bc8e190e9a90fc43f5f68c499062cd58db3ebe.tar.gz |
Add profile for compilation with ECJ (#522)
-rwxr-xr-x | .travis.sh | 2 | ||||
-rw-r--r-- | .travis.yml | 2 | ||||
-rw-r--r-- | org.jacoco.build/pom.xml | 34 | ||||
-rw-r--r-- | org.jacoco.doc/docroot/doc/build.html | 9 |
4 files changed, 46 insertions, 1 deletions
@@ -82,7 +82,7 @@ case "$JDK" in mvn -V -B -e verify -Dbytecode.version=1.7 ;; 8 | 8-ea) - mvn -V -B -e verify -Dbytecode.version=1.8 + mvn -V -B -e verify -Dbytecode.version=1.8 -Decj=${ECJ:-} ;; 9-ea | 9-ea-stable) # Groovy version should be updated to get rid of "--add-opens" options (see https://twitter.com/CedricChampeau/status/807285853580103684) diff --git a/.travis.yml b/.travis.yml index 36ea75d0..19f5d2b7 100644 --- a/.travis.yml +++ b/.travis.yml @@ -16,6 +16,8 @@ env: - JDK=6 - JDK=7 - JDK=8 + - JDK=8 + ECJ=true - JDK=8-ea - JDK=9-ea - JDK=9-ea-stable diff --git a/org.jacoco.build/pom.xml b/org.jacoco.build/pom.xml index ad6472c9..e746d6ac 100644 --- a/org.jacoco.build/pom.xml +++ b/org.jacoco.build/pom.xml @@ -687,6 +687,40 @@ </properties> </profile> + <!-- This profile is used for compilation with ECJ. --> + <profile> + <id>ecj</id> + <activation> + <property> + <name>ecj</name> + </property> + </activation> + <build> + <plugins> + <plugin> + <groupId>org.apache.maven.plugins</groupId> + <artifactId>maven-compiler-plugin</artifactId> + <version>3.6.0</version> + <configuration> + <compilerId>eclipse</compilerId> + </configuration> + <dependencies> + <dependency> + <groupId>org.eclipse.jdt.core.compiler</groupId> + <artifactId>ecj</artifactId> + <version>4.6.1</version> + </dependency> + <dependency> + <groupId>org.codehaus.plexus</groupId> + <artifactId>plexus-compiler-eclipse</artifactId> + <version>2.8.1</version> + </dependency> + </dependencies> + </plugin> + </plugins> + </build> + </profile> + <profile> <id>jdk16</id> <activation> diff --git a/org.jacoco.doc/docroot/doc/build.html b/org.jacoco.doc/docroot/doc/build.html index bc926567..89df34c3 100644 --- a/org.jacoco.doc/docroot/doc/build.html +++ b/org.jacoco.doc/docroot/doc/build.html @@ -152,6 +152,14 @@ </pre> <p> + Also Eclipse Compiler for Java can be used for compilation: +</p> + +<pre> + mvn clean install -Decj +</pre> + +<p> In addition JaCoCo can be compiled for higher class file versions than 1.5 specifying the property <code>bytecode.version</code>. Note that in this case the version of the JVM running Maven must be at least the version of the @@ -164,6 +172,7 @@ <li>Maven with 1.6 JDK: <code>mvn clean install -Djdk.version=1.6 -Dbytecode.version=1.6</code></li> <li>Maven with 1.7 JDK: <code>mvn clean install -Djdk.version=1.7 -Dbytecode.version=1.7</code></li> <li>Maven with 1.8 JDK: <code>mvn clean install -Djdk.version=1.8 -Dbytecode.version=1.8</code></li> + <li>Maven with 1.8 JDK: <code>mvn clean install -Djdk.version=1.8 -Dbytecode.version=1.8 -Decj</code></li> <li>Maven with 1.9 JDK: <code>mvn clean install -Djdk.version=1.9 -Dbytecode.version=1.9</code></li> </ul> |