Skip to content

Commit 2d696b4

Browse files
updated module-info and replaced moditect-maven-plugin
1 parent 47a6c2c commit 2d696b4

File tree

2 files changed

+37
-43
lines changed

2 files changed

+37
-43
lines changed

pom.xml

Lines changed: 18 additions & 43 deletions
Original file line numberDiff line numberDiff line change
@@ -156,10 +156,26 @@
156156
<encoding>UTF-8</encoding>
157157
<showWarnings>true</showWarnings>
158158
</configuration>
159+
<executions>
160+
<execution>
161+
<id>java9</id>
162+
<phase>compile</phase>
163+
<goals>
164+
<goal>compile</goal>
165+
</goals>
166+
<configuration>
167+
<release>9</release>
168+
<compileSourceRoots>
169+
<compileSourceRoot>${project.basedir}/src/main/java9</compileSourceRoot>
170+
</compileSourceRoots>
171+
<multiReleaseOutput>true</multiReleaseOutput>
172+
</configuration>
173+
</execution>
174+
</executions>
159175
</plugin>
160176
<plugin>
161177
<artifactId>maven-shade-plugin</artifactId>
162-
<version>3.2.4</version>
178+
<version>3.4.0</version>
163179
<executions>
164180
<execution>
165181
<phase>package</phase>
@@ -179,7 +195,7 @@
179195
<relocations>
180196
<relocation>
181197
<pattern>org.bouncycastle</pattern>
182-
<shadedPattern>org.cryptomator.cryptolib.org.bouncycastle</shadedPattern>
198+
<shadedPattern>org.cryptomator.cryptolib.shaded.bouncycastle</shadedPattern>
183199
</relocation>
184200
</relocations>
185201
<filters>
@@ -194,47 +210,6 @@
194210
</execution>
195211
</executions>
196212
</plugin>
197-
<plugin>
198-
<groupId>org.moditect</groupId>
199-
<artifactId>moditect-maven-plugin</artifactId>
200-
<version>1.0.0.RC2</version>
201-
<executions>
202-
<execution>
203-
<id>add-module-infos</id>
204-
<phase>package</phase>
205-
<goals>
206-
<goal>add-module-info</goal>
207-
</goals>
208-
<configuration>
209-
<jvmVersion>9</jvmVersion>
210-
<overwriteExistingFiles>true</overwriteExistingFiles>
211-
<module>
212-
<moduleInfoSource>
213-
module org.cryptomator.cryptolib {
214-
requires org.cryptomator.siv;
215-
requires com.google.gson;
216-
requires transitive com.google.common;
217-
requires org.slf4j;
218-
219-
exports org.cryptomator.cryptolib.api;
220-
exports org.cryptomator.cryptolib.common;
221-
222-
opens org.cryptomator.cryptolib.common to com.google.gson;
223-
224-
uses org.cryptomator.cryptolib.api.CryptorProvider;
225-
226-
provides org.cryptomator.cryptolib.api.CryptorProvider
227-
with org.cryptomator.cryptolib.v1.CryptorProviderImpl, org.cryptomator.cryptolib.v2.CryptorProviderImpl;
228-
}
229-
</moduleInfoSource>
230-
</module>
231-
<jdepsExtraArgs>
232-
<arg>--multi-release=9</arg>
233-
</jdepsExtraArgs>
234-
</configuration>
235-
</execution>
236-
</executions>
237-
</plugin>
238213
<plugin>
239214
<groupId>org.apache.maven.plugins</groupId>
240215
<artifactId>maven-surefire-plugin</artifactId>

src/main/java9/module-info.java

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
module org.cryptomator.cryptolib {
2+
requires static org.bouncycastle.provider; // will be shaded
3+
requires static org.bouncycastle.pkix; // will be shaded
4+
requires jdk.crypto.ec; // required at runtime for ECC
5+
requires org.cryptomator.siv;
6+
requires com.google.gson;
7+
requires transitive com.google.common;
8+
requires org.slf4j;
9+
10+
exports org.cryptomator.cryptolib.api;
11+
exports org.cryptomator.cryptolib.common;
12+
13+
opens org.cryptomator.cryptolib.common to com.google.gson;
14+
15+
uses org.cryptomator.cryptolib.api.CryptorProvider;
16+
17+
provides org.cryptomator.cryptolib.api.CryptorProvider
18+
with org.cryptomator.cryptolib.v1.CryptorProviderImpl, org.cryptomator.cryptolib.v2.CryptorProviderImpl;
19+
}

0 commit comments

Comments
 (0)