Skip to content

Conversation

@chrisrueger
Copy link
Contributor

@chrisrueger chrisrueger commented Dec 27, 2025

Closes #7022

Guava

  • Removed org.jspecify.jspecify and com.google.errorprone.annotations
  • following packages are now private-package (instead of Import-Package)
com.google.common.util.concurrent.internal.*

Hopefully makes life easier for eclipse-platform/eclipse.platform.releng.aggregator#3579 (comment)

Full MANIFEST.MF (Print view from JAR viewer):

[MANIFEST]

Automatic-Module-Name                   org.bndtools.templating
Bundle-ActivationPolicy                 lazy
Bundle-Copyright                        Copyright (c) Neil Bartlett (2009, 2025) and others. All Rights Reserved.
Bundle-Developers                       bjhargrave;email="bj@hargrave.dev";name="BJ Hargrave";organization=IBM;organizationUrl="https://developer.ibm.com";roles=developer;timezone="America/New_York";url="https://github.com/bjhargrave"
                                        chrisrueger;email="chrisrueger@gmail.com";name="Christoph Rueger";organization="Synesty GmbH";organizationUrl="https://synesty.com/";roles=developer;timezone="Europe/Berlin"
                                        peterkir;email="peter@klib.io";name="Peter Kirschner";organization="Kirschners GmbH";organizationUrl="https://peterkir.github.io/";roles=developer;timezone="Europe/Berlin";url="https://peterkir.github.io"
                                        pkriens;email="Peter.Kriens@aQute.biz";name="Peter Kriens";organization=Bndtools;organizationUrl="https://github.com/bndtools";roles="architect,developer";timezone=1
                                        rotty3000;email="raymond.auge@liferay.com";name="Ray Augé";organization="Liferay Inc.";organizationUrl="https://www.liferay.com";roles=developer;timezone="America/New_York";url="https://rotty3000.github.io"
Bundle-DocURL                           https://bndtools.org/
Bundle-License                          (Apache-2.0 OR EPL-2.0);description="This program and the accompanying materials are made available under the terms of the Apache License, Version 2.0, or the Eclipse Public License 2.0.";link="https://opensource.org/licenses/Apache-2.0,https://opensource.org/licenses/EPL-2.0"
Bundle-ManifestVersion                  2
Bundle-Name                             org.bndtools.templating
Bundle-SCM                              connection=scm:git:https://github.com/bndtools/bnd.git
                                        developerConnection=scm:git:git@github.com:bndtools/bnd.git
                                        tag=7.3.0-SNAPSHOT
                                        url=https://github.com/bndtools/bnd
Bundle-SymbolicName                     org.bndtools.templating
Bundle-Vendor                           Bndtools https://bndtools.org/
Bundle-Version                          7.3.0.202512290835-SNAPSHOT
Export-Package                          org.bndtools.templating.util;version="1.0.0";uses:="org.osgi.service.metatype"
                                        org.bndtools.templating;version="2.0.0";uses:="aQute.service.reporter,org.eclipse.core.runtime,org.osgi.framework,org.osgi.service.metatype,org.osgi.util.promise"
Git-Descriptor                          7.3.0.DEV-96-gf5db14361
Git-SHA                                 f5db14361114564f2162531fbcfb160e2aac43fe
Import-Package                          aQute.bnd.exceptions;version="[3.0,4)"
                                        aQute.bnd.osgi;version="[7.6,8)"
                                        aQute.service.reporter;version="[1.3,2)"
                                        android.os;resolution:=optional
                                        com.google.appengine.api.utils;resolution:=optional
                                        com.google.appengine.api;resolution:=optional
                                        com.google.apphosting.api;resolution:=optional
                                        javax.crypto
                                        javax.crypto.spec
                                        javax.swing
                                        javax.swing.border
                                        javax.swing.event
                                        javax.swing.text
                                        javax.swing.tree
                                        org.eclipse.core.runtime;bundle-symbolic-name="org.eclipse.core.runtime";bundle-version="[3.30,4)"
                                        org.osgi.framework;version="[1.8,2)"
                                        org.osgi.service.metatype;version="[1.3,2)"
                                        org.osgi.util.promise;version="[1.3,2)"
                                        sun.misc;resolution:=optional
Manifest-Version                        1.0
Private-Package                         aQute.lib.io;version="4.5.0"
                                        aQute.lib.stringrover;version="1.2.0"
                                        aQute.libg.glob;version="1.6.0"
                                        com.github.mustachejava
                                        com.github.mustachejava.codes
                                        com.github.mustachejava.reflect
                                        com.github.mustachejava.reflect.guards
                                        com.github.mustachejava.resolver
                                        com.github.mustachejava.util
                                        com.google.common.base
                                        com.google.common.base.internal
                                        com.google.common.cache
                                        com.google.common.collect
                                        com.google.common.graph
                                        com.google.common.hash
                                        com.google.common.io
                                        com.google.common.math
                                        com.google.common.primitives
                                        com.google.common.util.concurrent
                                        com.google.common.util.concurrent.internal
                                        org.bndtools.templating.engine.mustache
                                        org.bndtools.templating.engine.st
                                        org.stringtemplate.v4
                                        org.stringtemplate.v4.compiler
                                        org.stringtemplate.v4.debug
                                        org.stringtemplate.v4.gui
                                        org.stringtemplate.v4.misc
                                        st4hidden.org.antlr.runtime
                                        st4hidden.org.antlr.runtime.misc
                                        st4hidden.org.antlr.runtime.tree
Provide-Capability                      osgi.service;objectClass:List<String>="org.bndtools.templating.TemplateEngine";uses:="org.bndtools.templating"
Require-Capability                      osgi.ee;filter:="(&(osgi.ee=JavaSE)(version=17))"
                                        osgi.extender;filter:="(&(osgi.extender=osgi.component)(version>=1.3.0)(!(version>=2.0.0)))"
SPDX-License-Identifier                 (Apache-2.0 OR EPL-2.0)
Service-Component                       OSGI-INF/org.bndtools.templating.engine.mustache.xml
                                        OSGI-INF/org.bndtools.templating.engine.st.xml


@chrisrueger chrisrueger force-pushed the 7022-make-deps-optional branch from 628703d to 02d083d Compare December 28, 2025 16:33
@chrisrueger chrisrueger changed the title Add optional imports for Guava / Error Prone Add optional imports for Guava / Error Prone / org.junit.platform Dec 28, 2025
@chrisrueger chrisrueger force-pushed the 7022-make-deps-optional branch from 02d083d to 296e0c2 Compare December 28, 2025 19:03
@chrisrueger
Copy link
Contributor Author

@laeubi since you were also part of eclipse-platform/eclipse.platform.releng.aggregator#3579

Are you ok with the changes?

@chrisrueger chrisrueger force-pushed the 7022-make-deps-optional branch from 296e0c2 to aa72f64 Compare December 28, 2025 20:21
Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

This PR reduces dependency pain for consumers of bnd by making certain dependencies private-package and making JUnit Platform imports optional.

  • Converts Guava/Error Prone/jspecify from Import-Package to private-package in org.bndtools.templating
  • Makes org.junit.platform imports optional in biz.aQute.tester.junit-platform to support consumers using JUnit >= 1.13

Reviewed changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated 1 comment.

File Description
org.bndtools.templating/bnd.bnd Adds com.google.errorprone.annotations and com.google.guava.failureaccess as compile dependencies and includes them in -conditionalpackage to make them private-package instead of Import-Package
biz.aQute.tester.junit-platform/bnd.bnd Adds resolution:=optional to org.junit.platform imports to reduce consumer pain when using JUnit versions >= 1.13

Copy link

@merks merks left a comment

Choose a reason for hiding this comment

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

That looks like it will be better and is analogous to other dependencies that haven't been causing problems...

@chrisrueger chrisrueger force-pushed the 7022-make-deps-optional branch from dec9cc3 to f5db143 Compare December 29, 2025 08:38
Eliminated org.jspecify.jspecify and com.google.errorprone.annotations from the build and import configurations as they are no longer required. Updated Import-Package to explicitly exclude these packages.

Signed-off-by: Christoph Rueger <chrisrueger@gmail.com>

make errorprone / guava.failureaccess private

Remove packages from Import-Package for com.google.common.util.concurrent.internal and com.google.errorprone.annotations.

Signed-off-by: Christoph Rueger <chrisrueger@gmail.com>

make org.junit.platform resolution:=optional,

to avoid problems for consumers of bnd (like Eclipse who are on higher JUnit version eclipse-platform/eclipse.platform.releng.aggregator#3579)

Signed-off-by: Christoph Rueger <chrisrueger@gmail.com>
@chrisrueger chrisrueger force-pushed the 7022-make-deps-optional branch from f5db143 to eeb5bcc Compare December 29, 2025 09:31
@chrisrueger chrisrueger changed the title Add optional imports for Guava / Error Prone / org.junit.platform Add optional imports for Guava / Error Prone Dec 29, 2025
@chrisrueger
Copy link
Contributor Author

I removed changes for biz.aQute.tester.junit-platform, because #7000 seems to be a better fix for that.

So this PR here is mainly about org.bndtools.templating now

@chrisrueger chrisrueger merged commit 767a288 into bndtools:master Dec 29, 2025
9 checks passed
@chrisrueger
Copy link
Contributor Author

@merks org.bndtools.templating 7.3.0 SNAPSHOT is available here https://bndtools.jfrog.io/artifactory/update-snapshot/org/bndtools/org.bndtools.templating/7.3.0-SNAPSHOT/org.bndtools.templating-7.3.0-20251229.122458-34.jar in case you want to have a look at it.

@merks
Copy link

merks commented Dec 29, 2025

@chrisrueger

Looking at the MANIFEST.MF content, everything looks sensible and is structured with sensible version ranges. Thanks!!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Make some dependencies optional to avoid problems for consumers after 7.2.0 upgrade

3 participants