Skip to content

Commit 534382a

Browse files
committed
Embed the google cache dependency in the bundle
Guava is known as a bit "problematic" dependency, as lemminx only uses guava-cache, this can be embedded in the bundle and be made embedded package. This changes the used felix-bundle to bnd-maven-plugin with the conditionalpackage to include the caching api in the generated bundle Signed-off-by: Christoph Läubrich <laeubi@laeubi-soft.de>
1 parent 244f248 commit 534382a

3 files changed

Lines changed: 34 additions & 20 deletions

File tree

org.eclipse.lemminx/pom.xml

Lines changed: 16 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -72,13 +72,26 @@
7272
</configuration>
7373
</plugin>
7474
<plugin>
75-
<groupId>org.apache.felix</groupId>
76-
<artifactId>maven-bundle-plugin</artifactId>
75+
<groupId>biz.aQute.bnd</groupId>
76+
<artifactId>bnd-maven-plugin</artifactId>
77+
<executions>
78+
<execution>
79+
<id>bnd-process</id>
80+
<goals>
81+
<goal>bnd-process</goal>
82+
</goals>
83+
<configuration>
84+
<bnd><![CDATA[
85+
Bundle-SymbolicName: ${project.artifactId}
86+
-conditionalpackage: com.google.common.cache
87+
]]></bnd>
88+
</configuration>
89+
</execution>
90+
</executions>
7791
</plugin>
7892
<plugin>
7993
<groupId>org.apache.maven.plugins</groupId>
8094
<artifactId>maven-jar-plugin</artifactId>
81-
<version>3.3.0</version>
8295
<executions>
8396
<execution>
8497
<goals>

org.eclipse.lemminx/src/main/resources/about.html

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,21 @@ <h3>License</h3>
3232
code in the Content and such source code may be obtained at <a
3333
href="https://www.eclipse.org/">https://www.eclipse.org</a>.
3434
</p>
35+
36+
<p>
37+
The content in the package <code>com.google.common.cache</code> is
38+
licensed under the Apache License, Version 2.0 (the "License");
39+
you may not use this except in compliance with the License.
40+
You may obtain a copy of the License at
41+
42+
http://www.apache.org/licenses/LICENSE-2.0
43+
44+
Unless required by applicable law or agreed to in writing, software
45+
distributed under the License is distributed on an "AS IS" BASIS,
46+
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
47+
See the License for the specific language governing permissions and
48+
limitations under the License.
49+
</p>
3550

3651
</body>
3752

pom.xml

Lines changed: 3 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -159,23 +159,9 @@
159159
</configuration>
160160
</plugin>
161161
<plugin>
162-
<groupId>org.apache.felix</groupId>
163-
<artifactId>maven-bundle-plugin</artifactId>
164-
<version>5.1.9</version>
165-
<executions>
166-
<execution>
167-
<id>bundle-manifest</id>
168-
<phase>process-classes</phase>
169-
<goals>
170-
<goal>manifest</goal>
171-
</goals>
172-
<configuration>
173-
<instructions>
174-
<Bundle-SymbolicName>${project.artifactId}</Bundle-SymbolicName>
175-
</instructions>
176-
</configuration>
177-
</execution>
178-
</executions>
162+
<groupId>biz.aQute.bnd</groupId>
163+
<artifactId>bnd-maven-plugin</artifactId>
164+
<version>6.4.0</version>
179165
</plugin>
180166
<plugin>
181167
<groupId>org.apache.maven.plugins</groupId>

0 commit comments

Comments
 (0)