@ -1,20 +1,13 @@
%bcond_with bootstrap
%bcond_with bootstrap
%if %{without bootstrap} && %{undefined rhel}
%bcond_without bnd_maven_plugin
%else
%bcond_with bnd_maven_plugin
%endif
Name: aqute-bnd
Name: aqute-bnd
Version: 6.3.1
Version: 5.2.0
Release: 11 %{?dist}
Release: 7%{?dist}
Summary: BND Tool
Summary: BND Tool
# Part of jpm is under BSD, but jpm is not included in binary RPM
# Part of jpm is under BSD, but jpm is not included in binary RPM
License: Apache-2.0 OR EPL-2.0
License: ASL 2.0 or EPL-2.0
URL: https://bnd.bndtools.org/
URL: https://bnd.bndtools.org/
BuildArch: noarch
BuildArch: noarch
ExclusiveArch: %{java_arches} noarch
Source0: %{name}-%{version}.tar.gz
Source0: %{name}-%{version}.tar.gz
# removes bundled jars from upstream tarball
# removes bundled jars from upstream tarball
@ -22,49 +15,30 @@ Source0: %{name}-%{version}.tar.gz
# ./generate-tarball.sh
# ./generate-tarball.sh
Source1: generate-tarball.sh
Source1: generate-tarball.sh
# Auxiliary parent pom, packager-written
Source2: parent.pom
Source2: aggregator.pom
Source3: https://repo1.maven.org/maven2/biz/aQute/bnd/aQute.libg/%{version}/aQute.libg-%{version}.pom
Source3: https://repo1.maven.org/maven2/biz/aQute/bnd/aQute.libg/%{version}/aQute.libg-%{version}.pom
Source4: https://repo1.maven.org/maven2/biz/aQute/bnd/biz.aQute.bnd/%{version}/biz.aQute.bnd-%{version}.pom
Source4: https://repo1.maven.org/maven2/biz/aQute/bnd/biz.aQute.bnd/%{version}/biz.aQute.bnd-%{version}.pom
Source5: https://repo1.maven.org/maven2/biz/aQute/bnd/biz.aQute.bndlib/%{version}/biz.aQute.bndlib-%{version}.pom
Source5: https://repo1.maven.org/maven2/biz/aQute/bnd/biz.aQute.bndlib/%{version}/biz.aQute.bndlib-%{version}.pom
Source6: https://repo1.maven.org/maven2/biz/aQute/bnd/biz.aQute.bnd.annotation/%{version}/biz.aQute.bnd.annotation-%{version}.pom
Source6: https://repo1.maven.org/maven2/biz/aQute/bnd/biz.aQute.bnd.annotation/%{version}/biz.aQute.bnd.annotation-%{version}.pom
Source7: https://repo1.maven.org/maven2/biz/aQute/bnd/biz.aQute.bnd.ant/%{version}/biz.aQute.bnd.ant-%{version}.pom
Source8: https://repo1.maven.org/maven2/biz/aQute/bnd/biz.aQute.bnd.util/%{version}/biz.aQute.bnd.util-%{version}.pom
Patch1: 0001-Disable-removed-commands.patch
Patch1: 0001-Disable-removed-commands.patch
Patch2: 0002-Port-to-OSGI-7.0.0.patch
Patch2: 0002-Port-to-OSGI-7.0.0.patch
Patch3: 0003-Remove-unmet-dependencies.patch
Patch4: 0004-Port-to-OpenJDK-21.patch
BuildRequires: maven-local
%if %{with bootstrap}
%if %{with bootstrap}
BuildRequires: javapackages-bootstrap
BuildRequires: javapackages-bootstrap
%else
%else
BuildRequires: maven-local
BuildRequires: mvn(org.apache.ant:ant)
BuildRequires: mvn(org.codehaus.plexus:plexus-component-metadata)
BuildRequires: mvn(org.junit:junit-bom:pom:)
BuildRequires: mvn(org.osgi:osgi.annotation)
BuildRequires: mvn(org.osgi:osgi.annotation)
BuildRequires: mvn(org.osgi:osgi.cmpn)
BuildRequires: mvn(org.osgi:osgi.cmpn)
BuildRequires: mvn(org.osgi:osgi.core)
BuildRequires: mvn(org.osgi:osgi.core)
BuildRequires: mvn(org.slf4j:slf4j-api)
BuildRequires: mvn(org.slf4j:slf4j-api)
BuildRequires: mvn(org.slf4j:slf4j-simple)
BuildRequires: mvn(org.slf4j:slf4j-simple)
%endif
%endif
%if %{with bnd_maven_plugin}
BuildRequires: mvn(org.apache.maven.plugin-tools:maven-plugin-annotations)
BuildRequires: mvn(org.apache.maven.plugins:maven-plugin-plugin)
BuildRequires: mvn(org.apache.maven.plugins:maven-source-plugin)
BuildRequires: mvn(org.apache.maven.shared:maven-mapping)
BuildRequires: mvn(org.apache.maven:maven-artifact)
BuildRequires: mvn(org.apache.maven:maven-compat)
BuildRequires: mvn(org.apache.maven:maven-core)
BuildRequires: mvn(org.apache.maven:maven-plugin-api)
BuildRequires: mvn(org.eclipse.aether:aether-api)
BuildRequires: mvn(org.sonatype.plexus:plexus-build-api)
%endif
# Explicit javapackages-tools requires since bnd script uses
# Explicit javapackages-tools requires since bnd script uses
# /usr/share/java-utils/java-functions
# /usr/share/java-utils/java-functions
Requires: javapackages-tools
Requires: javapackages-tools
Requires: java-devel
%description
%description
The bnd tool helps you create and diagnose OSGi bundles.
The bnd tool helps you create and diagnose OSGi bundles.
@ -85,14 +59,6 @@ Summary: BND library
%description -n aqute-bndlib
%description -n aqute-bndlib
%{summary}.
%{summary}.
%if %{with bnd_maven_plugin}
%package -n bnd-maven-plugin
Summary: BND Maven plugin
%description -n bnd-maven-plugin
%{summary}.
%endif
%package javadoc
%package javadoc
Summary: Javadoc for %{name}
Summary: Javadoc for %{name}
@ -104,30 +70,24 @@ API documentation for %{name}.
%patch1 -p1
%patch1 -p1
%patch2 -p1
%patch2 -p1
%patch 3 -p1
%patch 4 -p1
# the commands pull in more dependencies than we want (felix-resolver, jetty)
# the commands pull in more dependencies than we want (felix-resolver, jetty)
rm biz.aQute.bnd/src/aQute/bnd/main/{ExportReportCommand,MbrCommand,RemoteCommand,ReporterLogger,ResolveCommand,Shell}.java
rm biz.aQute.bnd/src/aQute/bnd/main/{ExportReportCommand,MbrCommand,RemoteCommand,ReporterLogger,ResolveCommand,Shell}.java
cp %SOURCE2 pom.xml
sed 's/@VERSION@/%{version}/' %SOURCE2 > pom.xml
sed -i 's|${Bundle-Version}|%{version}|' biz.aQute.bndlib/src/aQute/bnd/osgi/bnd.info
sed -i 's|${Bundle-Version}|%{version}|' biz.aQute.bndlib/src/aQute/bnd/osgi/bnd.info
%if %{without bnd_maven_plugin}
%pom_disable_module maven
%endif
# libg
# libg
pushd aQute.libg
pushd aQute.libg
cp -p %{SOURCE3} pom.xml
cp -p %{SOURCE3} pom.xml
%pom_add_parent org.fedoraproject.xmvn.aqute-bnd:aggregator:any
%pom_add_parent biz.aQute.bnd:parent:%{version}
%pom_add_dep org.osgi:osgi.cmpn
%pom_add_dep org.osgi:osgi.cmpn
popd
popd
# bnd.annotation
# bnd.annotation
pushd biz.aQute.bnd.annotation
pushd biz.aQute.bnd.annotation
cp -p %{SOURCE6} pom.xml
cp -p %{SOURCE6} pom.xml
%pom_add_parent org.fedoraproject.xmvn.aqute-bnd:aggregator:any
%pom_add_parent biz.aQute.bnd:parent:%{version}
%pom_add_dep org.osgi:osgi.core
%pom_add_dep org.osgi:osgi.core
%pom_add_dep org.osgi:osgi.cmpn
%pom_add_dep org.osgi:osgi.cmpn
popd
popd
@ -135,43 +95,27 @@ popd
# bndlib
# bndlib
pushd biz.aQute.bndlib
pushd biz.aQute.bndlib
cp -p %{SOURCE5} pom.xml
cp -p %{SOURCE5} pom.xml
%pom_add_parent org.fedoraproject.xmvn.aqute-bnd:aggregator:any
%pom_add_parent biz.aQute.bnd:parent:%{version}
%pom_add_dep org.osgi:osgi.cmpn
%pom_add_dep org.osgi:osgi.cmpn
%pom_add_dep biz.aQute.bnd:aQute.libg:%{version}
%pom_add_dep biz.aQute.bnd:aQute.libg:%{version}
%pom_add_dep biz.aQute.bnd:biz.aQute.bnd.annotation:%{version}
%pom_add_dep biz.aQute.bnd:biz.aQute.bnd.annotation:%{version}
popd
popd
# bnd.ant
pushd biz.aQute.bnd.ant
cp -p %{SOURCE7} pom.xml
%pom_add_parent org.fedoraproject.xmvn.aqute-bnd:aggregator:any
popd
# bnd
# bnd
cp -r biz.aQute.bnd.exporters/src/aQute/bnd/exporter biz.aQute.bnd/src/aQute/bnd/
cp -r biz.aQute.bnd.exporters/src/aQute/bnd/exporter biz.aQute.bnd/src/aQute/bnd/
pushd biz.aQute.bnd
pushd biz.aQute.bnd
cp -p %{SOURCE4} pom.xml
cp -p %{SOURCE4} pom.xml
%pom_add_parent org.fedoraproject.xmvn.aqute-bnd:aggregator:any
%pom_add_parent biz.aQute.bnd:parent:%{version}
%pom_remove_dep :biz.aQute.resolve
%pom_remove_dep :biz.aQute.resolve
%pom_remove_dep :biz.aQute.bnd.ant
%pom_remove_dep :biz.aQute.repository
%pom_remove_dep :biz.aQute.repository
%pom_remove_dep :biz.aQute.bnd.exporters
%pom_remove_dep :biz.aQute.bnd.exporters
%pom_remove_dep :biz.aQute.bnd.reporter
%pom_remove_dep :biz.aQute.bnd.reporter
%pom_remove_dep :biz.aQute.remote.api
%pom_remove_dep :biz.aQute.remote.api
%pom_remove_dep :snakeyaml
%pom_remove_dep :snakeyaml
%pom_remove_dep :jline
%pom_remove_dep :jline
%pom_remove_dep org.osgi:org.osgi.service.coordinator
%pom_remove_dep org.osgi:org.osgi.service.resolver
popd
# bnd.util
pushd biz.aQute.bnd.util
cp -p %{SOURCE8} pom.xml
%pom_add_parent org.fedoraproject.xmvn.aqute-bnd:aggregator:any
%pom_add_dep biz.aQute.bnd:aQute.libg:%{version}
popd
popd
%pom_remove_dep -r org.osgi:org.osgi.dto
%pom_remove_dep -r org.osgi:org.osgi.framework
%pom_remove_dep -r org.osgi:org.osgi.namespace.contract
%pom_remove_dep -r org.osgi:org.osgi.namespace.contract
%pom_remove_dep -r org.osgi:org.osgi.namespace.extender
%pom_remove_dep -r org.osgi:org.osgi.namespace.extender
%pom_remove_dep -r org.osgi:org.osgi.namespace.implementation
%pom_remove_dep -r org.osgi:org.osgi.namespace.implementation
@ -182,45 +126,20 @@ popd
%pom_remove_dep -r org.osgi:org.osgi.service.serviceloader
%pom_remove_dep -r org.osgi:org.osgi.service.serviceloader
%pom_remove_dep -r org.osgi:org.osgi.util.function
%pom_remove_dep -r org.osgi:org.osgi.util.function
%pom_remove_dep -r org.osgi:org.osgi.util.promise
%pom_remove_dep -r org.osgi:org.osgi.util.promise
%pom_remove_dep -r org.osgi:org.osgi.util.tracker
%pom_xpath_remove -r pom:project/pom:dependencies/pom:dependency/pom:scope
%pom_xpath_remove -r pom:project/pom:dependencies/pom:dependency/pom:scope
# maven-plugins
cp -r biz.aQute.bnd.maven/src/aQute/bnd/maven/lib/configuration maven/bnd-maven-plugin/src/main/java/aQute/bnd/maven/lib
cp -r biz.aQute.bnd.maven/src/aQute/bnd/maven/lib/executions maven/bnd-maven-plugin/src/main/java/aQute/bnd/maven/lib
pushd maven
%pom_remove_dep -r :biz.aQute.bnd.maven
# Unavailable reactor dependency - org.osgi.impl.bundle.repoindex.cli
%pom_disable_module bnd-indexer-maven-plugin
# Requires unbuilt parts of bnd
%pom_disable_module bnd-export-maven-plugin
%pom_disable_module bnd-reporter-maven-plugin
%pom_disable_module bnd-resolver-maven-plugin
%pom_disable_module bnd-run-maven-plugin
%pom_disable_module bnd-testing-maven-plugin
# Integration tests require Internet access
%pom_remove_plugin -r :maven-invoker-plugin
%pom_remove_plugin -r :maven-javadoc-plugin
%pom_remove_plugin -r :flatten-maven-plugin
popd
%mvn_alias biz.aQute.bnd:biz.aQute.bnd :bnd biz.aQute:bnd
%mvn_alias biz.aQute.bnd:biz.aQute.bnd :bnd biz.aQute:bnd
%mvn_alias biz.aQute.bnd:biz.aQute.bndlib :bndlib biz.aQute:bndlib
%mvn_alias biz.aQute.bnd:biz.aQute.bndlib :bndlib biz.aQute:bndlib
%mvn_package biz.aQute.bnd:biz.aQute.bndlib bndlib
%mvn_package biz.aQute.bnd:biz.aQute.bndlib bndlib
%mvn_package biz.aQute.bnd:biz.aQute.bnd.annotation bndlib
%mvn_package biz.aQute.bnd:biz.aQute.bnd.annotation bndlib
%mvn_package biz.aQute.bnd:aQute.libg bndlib
%mvn_package biz.aQute.bnd:aQute.libg bndlib
%mvn_package org.fedoraproject.xmvn.aqute-bnd:aggregator __noinstall
%mvn_package biz.aQute.bnd:parent __noinstall
%mvn_package biz.aQute.bnd:bnd-plugin-parent __noinstall
%mvn_package biz.aQute.bnd:bnd-plugin-parent __noinstall
%if %{with bnd_maven_plugin}
%mvn_package biz.aQute.bnd:bnd-maven-plugin maven
%mvn_package biz.aQute.bnd:bnd-baseline-maven-plugin maven
%endif
%build
%build
%mvn_build
%mvn_build -- -Dproject.build.sourceEncoding=UTF-8
%install
%install
%mvn_install
%mvn_install
@ -238,71 +157,14 @@ echo "aqute-bnd slf4j/api slf4j/simple osgi-annotation osgi-core osgi-compendium
%files -n aqute-bndlib -f .mfiles-bndlib
%files -n aqute-bndlib -f .mfiles-bndlib
%license LICENSE
%license LICENSE
%if %{with bnd_maven_plugin}
%files -n bnd-maven-plugin -f .mfiles-maven
%endif
%files javadoc -f .mfiles-javadoc
%files javadoc -f .mfiles-javadoc
%license LICENSE
%license LICENSE
%changelog
%changelog
* Tue Oct 29 2024 Troy Dawson <tdawson@redhat.com> - 6.3.1-11
* Mon Dec 20 2021 Mikolaj Izdebski <mizdebsk@redhat.com> - 5.2.0-7
- Bump release for October 2024 mass rebuild:
- Add requires on java-devel
Resolves: RHEL-64018
* Mon Aug 05 2024 Mikolaj Izdebski <mizdebsk@redhat.com> - 6.3.1-10
- Port to OpenJDK 21
- Resolves: RHEL-52710
* Thu Aug 01 2024 Troy Dawson <tdawson@redhat.com> - 6.3.1-9
- Bump release for Aug 2024 java mass rebuild
* Mon Jun 24 2024 Troy Dawson <tdawson@redhat.com> - 6.3.1-8
- Bump release for June 2024 mass rebuild
* Fri Jan 19 2024 Fedora Release Engineering <releng@fedoraproject.org> - 6.3.1-7
- Rebuilt for https://fedoraproject.org/wiki/Fedora_40_Mass_Rebuild
* Fri Sep 01 2023 Mikolaj Izdebski <mizdebsk@redhat.com> - 6.3.1-6
- Convert License tag to SPDX format
* Wed Jul 19 2023 Fedora Release Engineering <releng@fedoraproject.org> - 6.3.1-5
- Rebuilt for https://fedoraproject.org/wiki/Fedora_39_Mass_Rebuild
* Wed Jun 07 2023 Mikolaj Izdebski <mizdebsk@redhat.com> - 6.3.1-4
- Conditionally disable bnd-maven-plugin
* Wed Jan 18 2023 Fedora Release Engineering <releng@fedoraproject.org> - 6.3.1-3
- Rebuilt for https://fedoraproject.org/wiki/Fedora_38_Mass_Rebuild
* Tue Nov 08 2022 Stephen Gallagher <sgallagh@redhat.com> - 6.3.1-2
- Re-enable maven plugin for RHEL 10+
* Wed Sep 07 2022 Marian Koncek <mkoncek@redhat.com> - 6.3.1-1
* Fri Dec 17 2021 Mattias Ellert <mattias.ellert@physics.uu.se> - 5.2.0-6
- Update to upstream version 6.3.1
* Wed Jul 20 2022 Fedora Release Engineering <releng@fedoraproject.org> - 6.2.0-2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_37_Mass_Rebuild
* Tue May 03 2022 Marian Koncek <mkoncek@redhat.com> - 6.2.0-1
- Update to upstream version 6.2.0
* Sat Feb 05 2022 Jiri Vanek <jvanek@redhat.com> - 5.2.0-9
- Rebuilt for java-17-openjdk as system jdk
* Wed Jan 19 2022 Fedora Release Engineering <releng@fedoraproject.org> - 5.2.0-8
- Rebuilt for https://fedoraproject.org/wiki/Fedora_36_Mass_Rebuild
* Mon Nov 22 2021 Didik Supriadi <didiksupriadi41@fedoraproject.org> - 5.2.0-7
- Enable biz.aQute.bnd.ant
* Fri Sep 24 2021 Mikolaj Izdebski <mizdebsk@redhat.com> - 5.2.0-6
- Rename maven_plugin build conditional to bnd_maven_plugin
* Tue Aug 10 2021 Sérgio Basto <sergio@serjux.com> - 5.2.0-5
- reenable bnd-maven-plugin
* Mon Aug 02 2021 Mattias Ellert <mattias.ellert@physics.uu.se> - 5.2.0-4
- Add parent to biz.aQute.bnd/pom.xml (fixes [WARNING] JAR will be
- Add parent to biz.aQute.bnd/pom.xml (fixes [WARNING] JAR will be
empty - no content was marked for inclusion!)
empty - no content was marked for inclusion!)
- Remove scope from dependencies in pom.xml files (fixes missing
- Remove scope from dependencies in pom.xml files (fixes missing
@ -310,10 +172,17 @@ echo "aqute-bnd slf4j/api slf4j/simple osgi-annotation osgi-core osgi-compendium
the rpm dependency generator)
the rpm dependency generator)
- Drop some more commands: shell, exportreport, mbr (uses parts that
- Drop some more commands: shell, exportreport, mbr (uses parts that
are not packaged)
are not packaged)
- Resolves: rhbz#1985566
- Resolves: rhbz#2033709
* Mon Aug 09 2021 Mohan Boddu <mboddu@redhat.com> - 5.2.0-5
- Rebuilt for IMA sigs, glibc 2.34, aarch64 flags
Related: rhbz#1991688
* Wed Jun 09 2021 Mikolaj Izdebski <mizdebsk@redhat.com> - 5.2.0-4
- Rebuild to workaround DistroBaker issue
* Wed Jul 21 2021 Fedora Release Engineering <releng@fedoraproject.org> - 5.2.0-3
* Tue Jun 08 2021 Mikolaj Izdebski <mizdebsk@redhat.com > - 5.2.0-3
- Rebuilt for https://fedoraproject.org/wiki/Fedora_35_Mass_Rebuild
- Bootstrap Maven for CentOS Stream 9
* Mon May 17 2021 Mikolaj Izdebski <mizdebsk@redhat.com> - 5.2.0-2
* Mon May 17 2021 Mikolaj Izdebski <mizdebsk@redhat.com> - 5.2.0-2
- Bootstrap build
- Bootstrap build