Skip to content

Add Java 11 support - Initial Phase #185

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 7 commits into from
Jan 26, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 15 additions & 0 deletions ndarray/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,10 @@
Utility library for N-dimensional data I/O operations.
</description>

<properties>
<java.module.name>org.tensorflow.ndarray</java.module.name>
</properties>

<dependencies>
<dependency>
<groupId>org.junit.jupiter</groupId>
Expand All @@ -57,6 +61,17 @@

<build>
<plugins>
<plugin>
<artifactId>maven-jar-plugin</artifactId>
<version>3.2.0</version>
<configuration>
<archive>
<manifestEntries>
<Automatic-Module-Name>${java.module.name}</Automatic-Module-Name>
</manifestEntries>
</archive>
</configuration>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-surefire-plugin</artifactId>
Expand Down
9 changes: 9 additions & 0 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -165,6 +165,15 @@
</repository>
</repositories>
</profile>

<profile>
<id>jdk11</id>
<properties>
<maven.compiler.source>11</maven.compiler.source>
<maven.compiler.target>11</maven.compiler.target>
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@JimClarke5 , can you add maven.compiler.release=11 as well, as suggested by @Craigacp ? Then we'll be good to merge it

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just pushed it.

<maven.compiler.release>11</maven.compiler.release>
</properties>
</profile>
</profiles>

<!-- http://central.sonatype.org/pages/requirements.html#developer-information -->
Expand Down
8 changes: 8 additions & 0 deletions tensorflow-core/tensorflow-core-api/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@
<javacpp.build.skip>${native.build.skip}</javacpp.build.skip>
<javacpp.parser.skip>${native.build.skip}</javacpp.parser.skip>
<javacpp.compiler.skip>${native.build.skip}</javacpp.compiler.skip>
<java.module.name>org.tensorflow.core.api</java.module.name>
</properties>

<dependencies>
Expand Down Expand Up @@ -330,6 +331,13 @@
<plugin>
<artifactId>maven-jar-plugin</artifactId>
<version>3.1.0</version>
<configuration>
<archive>
<manifestEntries>
<Automatic-Module-Name>${java.module.name}</Automatic-Module-Name>
</manifestEntries>
</archive>
</configuration>
<executions>
<execution>
<!--
Expand Down
19 changes: 15 additions & 4 deletions tensorflow-core/tensorflow-core-generator/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,10 @@
<name>TensorFlow Core Annotation Processor</name>
<description>Annotation processor for TensorFlow Java client</description>

<properties>
<java.module.name>org.tensorflow.core.generator</java.module.name>
</properties>

<dependencies>
<dependency>
<groupId>com.google.guava</groupId>
Expand All @@ -33,14 +37,21 @@

<build>
<plugins>
<plugin>
<artifactId>maven-jar-plugin</artifactId>
<version>3.2.0</version>
<configuration>
<archive>
<manifestEntries>
<Automatic-Module-Name>${java.module.name}</Automatic-Module-Name>
</manifestEntries>
</archive>
</configuration>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-compiler-plugin</artifactId>
<version>3.8.0</version>
<configuration>
<source>1.8</source>
<target>1.8</target>
</configuration>
</plugin>
</plugins>
</build>
Expand Down
2 changes: 2 additions & 0 deletions tensorflow-core/tensorflow-core-platform-gpu/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@
<properties>
<javacpp.moduleId>tensorflow-core-api</javacpp.moduleId>
<javacpp.platform.extension>-gpu</javacpp.platform.extension>
<java.module.name>org.tensorflow.core.platform.gpu</java.module.name>
</properties>

<dependencies>
Expand Down Expand Up @@ -80,6 +81,7 @@
<archive>
<manifestEntries>
<Class-Path>${javacpp.moduleId}.jar ${javacpp.moduleId}-linux-x86_64-gpu.jar ${javacpp.moduleId}-windows-x86_64-gpu.jar</Class-Path>
<Automatic-Module-Name>${java.module.name}</Automatic-Module-Name>
</manifestEntries>
</archive>
</configuration>
Expand Down
2 changes: 2 additions & 0 deletions tensorflow-core/tensorflow-core-platform-mkl-gpu/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@
<properties>
<javacpp.moduleId>tensorflow-core-api</javacpp.moduleId>
<javacpp.platform.extension>-mkl-gpu</javacpp.platform.extension>
<java.module.name>org.tensorflow.core.platform.mkl</java.module.name>
</properties>

<dependencies>
Expand Down Expand Up @@ -97,6 +98,7 @@
<archive>
<manifestEntries>
<Class-Path>${javacpp.moduleId}.jar ${javacpp.moduleId}-linux-x86_64-mkl-gpu.jar ${javacpp.moduleId}-windows-x86_64-mkl-gpu.jar</Class-Path>
<Automatic-Module-Name>${java.module.name}</Automatic-Module-Name>
</manifestEntries>
</archive>
</configuration>
Expand Down
2 changes: 2 additions & 0 deletions tensorflow-core/tensorflow-core-platform-mkl/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@
<properties>
<javacpp.moduleId>tensorflow-core-api</javacpp.moduleId>
<javacpp.platform.extension>-mkl</javacpp.platform.extension>
<java.module.name>org.tensorflow.core.platform.mkl</java.module.name>
</properties>

<dependencies>
Expand Down Expand Up @@ -115,6 +116,7 @@
<archive>
<manifestEntries>
<Class-Path>${javacpp.moduleId}.jar ${javacpp.moduleId}-linux-x86_64-mkl.jar ${javacpp.moduleId}-macosx-x86_64-mkl.jar ${javacpp.moduleId}-windows-x86_64-mkl.jar</Class-Path>
<Automatic-Module-Name>${java.module.name}</Automatic-Module-Name>
</manifestEntries>
</archive>
</configuration>
Expand Down
2 changes: 2 additions & 0 deletions tensorflow-core/tensorflow-core-platform/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,7 @@

<properties>
<javacpp.moduleId>tensorflow-core-api</javacpp.moduleId>
<java.module.name>org.tensorflow.core.platform</java.module.name>
</properties>

<dependencies>
Expand Down Expand Up @@ -91,6 +92,7 @@
<archive>
<manifestEntries>
<Class-Path>${javacpp.moduleId}.jar ${javacpp.moduleId}-linux-x86_64.jar ${javacpp.moduleId}-macosx-x86_64.jar ${javacpp.moduleId}-windows-x86_64.jar</Class-Path>
<Automatic-Module-Name>${java.module.name}</Automatic-Module-Name>
</manifestEntries>
</archive>
</configuration>
Expand Down
12 changes: 12 additions & 0 deletions tensorflow-framework/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,7 @@

<properties>
<javacpp.platform.extension></javacpp.platform.extension>
<java.module.name>org.tensorflow.framework</java.module.name>
</properties>

<dependencies>
Expand Down Expand Up @@ -74,6 +75,17 @@

<build>
<plugins>
<plugin>
<artifactId>maven-jar-plugin</artifactId>
<version>3.2.0</version>
<configuration>
<archive>
<manifestEntries>
<Automatic-Module-Name>${java.module.name}</Automatic-Module-Name>
</manifestEntries>
</archive>
</configuration>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-surefire-plugin</artifactId>
Expand Down