Skip to content

Commit cf09825

Browse files
committed
OSGI: Mark com.mongodb.crypt.capi as optional
Bnd needs some help marking optional dependency packages as optional. JAVA-3604
1 parent b8d844d commit cf09825

File tree

3 files changed

+15
-3
lines changed

3 files changed

+15
-3
lines changed

driver-reactive-streams/build.gradle

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,11 @@ ext {
6060
}
6161

6262
afterEvaluate {
63-
jar.manifest.attributes['Import-Package'] = 'org.bson.*,com.mongodb.*'
6463
jar.manifest.attributes['Automatic-Module-Name'] = 'org.mongodb.driver.reactivestreams'
6564
jar.manifest.attributes['Bundle-SymbolicName'] = 'org.mongodb.driver-reactivestreams'
65+
jar.manifest.attributes['Import-Package'] = [
66+
'org.bson.*',
67+
'com.mongodb.crypt.capi.*;resolution:=optional',
68+
'com.mongodb.*',
69+
].join(',')
6670
}

driver-scala/build.gradle

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -97,6 +97,10 @@ ext {
9797
}
9898

9999
afterEvaluate {
100-
jar.manifest.attributes['Import-Package'] = 'org.bson.*,com.mongodb.*'
101100
jar.manifest.attributes['Automatic-Module-Name'] = 'org.mongodb.scala.mongo-scala-driver'
101+
jar.manifest.attributes['Import-Package'] = [
102+
'org.bson.*',
103+
'com.mongodb.crypt.capi.*;resolution:=optional',
104+
'com.mongodb.*',
105+
].join(',')
102106
}

driver-sync/build.gradle

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,11 @@ tasks.withType(Checkstyle) {
4242
}
4343

4444
afterEvaluate {
45-
jar.manifest.attributes['Import-Package'] = 'org.bson.*,com.mongodb.*'
4645
jar.manifest.attributes['Automatic-Module-Name'] = 'org.mongodb.driver.sync.client'
4746
jar.manifest.attributes['Bundle-SymbolicName'] = 'org.mongodb.driver-sync'
47+
jar.manifest.attributes['Import-Package'] = [
48+
'org.bson.*',
49+
'com.mongodb.crypt.capi.*;resolution:=optional',
50+
'com.mongodb.*',
51+
].join(',')
4852
}

0 commit comments

Comments
 (0)