From f2bd89ea6079c3dbcfae4d0497075f6246cbbc65 Mon Sep 17 00:00:00 2001 From: Joe Schmetzer Date: Thu, 4 Jul 2024 21:28:27 +1000 Subject: [PATCH] Replace osgi plugin with bnd plugin --- build.gradle | 7 ++++--- hamcrest/hamcrest.gradle | 17 ++++++++++++----- 2 files changed, 16 insertions(+), 8 deletions(-) diff --git a/build.gradle b/build.gradle index 649823e1..2fd929c7 100644 --- a/build.gradle +++ b/build.gradle @@ -1,6 +1,7 @@ -apply plugin: 'signing' -//apply plugin: 'osgi' -apply plugin: 'maven-publish' +plugins { + id "signing" + id "maven-publish" +} group = "org.hamcrest" version = "3.0-SNAPSHOT" diff --git a/hamcrest/hamcrest.gradle b/hamcrest/hamcrest.gradle index 4172ba51..1cb83118 100644 --- a/hamcrest/hamcrest.gradle +++ b/hamcrest/hamcrest.gradle @@ -1,4 +1,6 @@ -//apply plugin: 'osgi' +plugins { + id "biz.aQute.bnd.builder" version "6.4.0" +} version = rootProject.version @@ -18,10 +20,15 @@ jar { 'Implementation-Vendor': 'hamcrest.org', 'Implementation-Version': version, 'Automatic-Module-Name': 'org.hamcrest' -// instruction 'Import-Package', '''javax.xml.namespace; resolution:=optional, -// javax.xml.xpath; resolution:=optional, -// org.w3c.dom; resolution:=optional, -// *''' + } + bundle { + bnd "Bundle-Name": "org.hamcrest", + "Bundle-SymbolicName": "org.hamcrest", + "Import-Package": "javax.xml.namespace; resolution:=optional," + + "javax.xml.xpath;resolution:=optional," + + "org.w3c.dom;resolution:=optional," + + "*", + "-exportcontents": "org.hamcrest.*" } }