This is an automated email from the ASF dual-hosted git repository. absurdfarce pushed a commit to branch 4.x in repository https://gitbox.apache.org/repos/asf/cassandra-java-driver.git
commit 342e2dcf47afab238f357ac2afde65b079ce6b79 Author: Lukasz Antoniak <[email protected]> AuthorDate: Fri Jan 10 16:16:26 2025 +0100 Conditionally compile shaded Guava module --- guava-shaded/pom.xml | 32 ++++++++++++++++++++++++++++++++ 1 file changed, 32 insertions(+) diff --git a/guava-shaded/pom.xml b/guava-shaded/pom.xml index f480f9258..ca8f0161b 100644 --- a/guava-shaded/pom.xml +++ b/guava-shaded/pom.xml @@ -56,6 +56,32 @@ </dependencies> <build> <plugins> + <plugin> + <!-- + Do not attempt to recompile the module if we are not running JVM 1.8. + Having additional Java source files and having to shade Guava will break + in CI environment, when we run 'mvn verify' on newer JVM and assume that + all classes have been compiled with JVM 1.8. + --> + <groupId>org.codehaus.mojo</groupId> + <artifactId>build-helper-maven-plugin</artifactId> + <version>1.12</version> + <executions> + <execution> + <id>regex-property</id> + <goals> + <goal>regex-property</goal> + </goals> + <configuration> + <name>maven.main.skip</name> + <value>${java.version}</value> + <regex>^(?!1.8).+</regex> + <replacement>true</replacement> + <failIfNoMatch>false</failIfNoMatch> + </configuration> + </execution> + </executions> + </plugin> <plugin> <artifactId>maven-shade-plugin</artifactId> <executions> @@ -95,6 +121,12 @@ </executions> </plugin> <plugin> + <!-- + Cleaning up target directory is required, because module's Java source files + (e.g. LexicographicalComparatorHolderSubstitution) will be left with + their original Java package AND eventually shaded one. This plugin removes + the Java class from its unshaded package. + --> <artifactId>maven-clean-plugin</artifactId> <executions> <execution> --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
