Added use-toolchains profile; note earlier change
diff --git a/pom.xml b/pom.xml
index f086adc..70b5d32 100644
--- a/pom.xml
+++ b/pom.xml
@@ -54,6 +54,8 @@
maven-resources-plugin 3.0.1 -> 3.0.2
maven-bundle-plugin 3.2.0 -> 3.3.0
jacaoco-maven-plugin 0.7.7.201606060606 -> 0.7.9
+Renamed artifactId to httpcomponents-parent
+Added use-toolchains profile; activated if ~/.m2/toolchains.xml exists
Version 8 - changes since version 7
===================================
@@ -878,6 +880,42 @@
</plugins>
</build>
</profile>
+
+ <profile>
+ <!--
+ Use toolchains plugin to select compiler version if the toolchains.xml file exists.
+ To override this behaviour, disable the profile using: -P-use-toolchains
+ -->
+ <id>use-toolchains</id>
+ <activation>
+ <file>
+ <exists>${user.home}/.m2/toolchains.xml</exists>
+ </file>
+ </activation>
+ <build>
+ <plugins>
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-toolchains-plugin</artifactId>
+ <version>1.1</version>
+ <configuration>
+ <toolchains>
+ <jdk>
+ <version>${maven.compiler.source}</version>
+ </jdk>
+ </toolchains>
+ </configuration>
+ <executions>
+ <execution>
+ <goals>
+ <goal>toolchain</goal>
+ </goals>
+ </execution>
+ </executions>
+ </plugin>
+ </plugins>
+ </build>
+ </profile>
</profiles>