d1c336
%bcond_with bootstrap
d1c336
d1c336
Name:           aqute-bnd
d1c336
Version:        5.2.0
d1c336
Release:        7%{?dist}
d1c336
Summary:        BND Tool
d1c336
# Part of jpm is under BSD, but jpm is not included in binary RPM
d1c336
License:        ASL 2.0 or EPL-2.0
d1c336
URL:            https://bnd.bndtools.org/
d1c336
BuildArch:      noarch
d1c336
d1c336
Source0:        %{name}-%{version}.tar.gz
d1c336
# removes bundled jars from upstream tarball
d1c336
# run as:
d1c336
# ./generate-tarball.sh
d1c336
Source1:        generate-tarball.sh
d1c336
d1c336
Source2:        parent.pom
d1c336
Source3:        https://repo1.maven.org/maven2/biz/aQute/bnd/aQute.libg/%{version}/aQute.libg-%{version}.pom
d1c336
Source4:        https://repo1.maven.org/maven2/biz/aQute/bnd/biz.aQute.bnd/%{version}/biz.aQute.bnd-%{version}.pom
d1c336
Source5:        https://repo1.maven.org/maven2/biz/aQute/bnd/biz.aQute.bndlib/%{version}/biz.aQute.bndlib-%{version}.pom
d1c336
Source6:        https://repo1.maven.org/maven2/biz/aQute/bnd/biz.aQute.bnd.annotation/%{version}/biz.aQute.bnd.annotation-%{version}.pom
d1c336
d1c336
Patch1:         0001-Disable-removed-commands.patch
d1c336
Patch2:         0002-Port-to-OSGI-7.0.0.patch
d1c336
d1c336
BuildRequires:  maven-local
d1c336
%if %{with bootstrap}
d1c336
BuildRequires:  javapackages-bootstrap
d1c336
%else
d1c336
BuildRequires:  mvn(org.osgi:osgi.annotation)
d1c336
BuildRequires:  mvn(org.osgi:osgi.cmpn)
d1c336
BuildRequires:  mvn(org.osgi:osgi.core)
d1c336
BuildRequires:  mvn(org.slf4j:slf4j-api)
d1c336
BuildRequires:  mvn(org.slf4j:slf4j-simple)
d1c336
%endif
d1c336
d1c336
# Explicit javapackages-tools requires since bnd script uses
d1c336
# /usr/share/java-utils/java-functions
d1c336
Requires:       javapackages-tools
d1c336
Requires:       java-devel
d1c336
d1c336
%description
d1c336
The bnd tool helps you create and diagnose OSGi bundles.
d1c336
The key functions are:
d1c336
- Show the manifest and JAR contents of a bundle
d1c336
- Wrap a JAR so that it becomes a bundle
d1c336
- Create a Bundle from a specification and a class path
d1c336
- Verify the validity of the manifest entries
d1c336
The tool is capable of acting as:
d1c336
- Command line tool
d1c336
- File format
d1c336
- Directives
d1c336
- Use of macros
d1c336
d1c336
%package -n aqute-bndlib
d1c336
Summary:        BND library
d1c336
d1c336
%description -n aqute-bndlib
d1c336
%{summary}.
d1c336
d1c336
%package javadoc
d1c336
Summary:        Javadoc for %{name}
d1c336
d1c336
%description javadoc
d1c336
API documentation for %{name}.
d1c336
d1c336
%prep
d1c336
%setup -q
d1c336
d1c336
%patch1 -p1
d1c336
%patch2 -p1
d1c336
d1c336
# the commands pull in more dependencies than we want (felix-resolver, jetty)
d1c336
rm biz.aQute.bnd/src/aQute/bnd/main/{ExportReportCommand,MbrCommand,RemoteCommand,ReporterLogger,ResolveCommand,Shell}.java
d1c336
d1c336
sed 's/@VERSION@/%{version}/' %SOURCE2 > pom.xml
d1c336
sed -i 's|${Bundle-Version}|%{version}|' biz.aQute.bndlib/src/aQute/bnd/osgi/bnd.info
d1c336
d1c336
# libg
d1c336
pushd aQute.libg
d1c336
cp -p %{SOURCE3} pom.xml
d1c336
%pom_add_parent biz.aQute.bnd:parent:%{version}
d1c336
%pom_add_dep org.osgi:osgi.cmpn
d1c336
popd
d1c336
d1c336
# bnd.annotation
d1c336
pushd biz.aQute.bnd.annotation
d1c336
cp -p %{SOURCE6} pom.xml
d1c336
%pom_add_parent biz.aQute.bnd:parent:%{version}
d1c336
%pom_add_dep org.osgi:osgi.core
d1c336
%pom_add_dep org.osgi:osgi.cmpn
d1c336
popd
d1c336
d1c336
# bndlib
d1c336
pushd biz.aQute.bndlib
d1c336
cp -p %{SOURCE5} pom.xml
d1c336
%pom_add_parent biz.aQute.bnd:parent:%{version}
d1c336
%pom_add_dep org.osgi:osgi.cmpn
d1c336
%pom_add_dep biz.aQute.bnd:aQute.libg:%{version}
d1c336
%pom_add_dep biz.aQute.bnd:biz.aQute.bnd.annotation:%{version}
d1c336
popd
d1c336
d1c336
# bnd
d1c336
cp -r biz.aQute.bnd.exporters/src/aQute/bnd/exporter biz.aQute.bnd/src/aQute/bnd/
d1c336
pushd biz.aQute.bnd
d1c336
cp -p %{SOURCE4} pom.xml
d1c336
%pom_add_parent biz.aQute.bnd:parent:%{version}
d1c336
%pom_remove_dep :biz.aQute.resolve
d1c336
%pom_remove_dep :biz.aQute.bnd.ant
d1c336
%pom_remove_dep :biz.aQute.repository
d1c336
%pom_remove_dep :biz.aQute.bnd.exporters
d1c336
%pom_remove_dep :biz.aQute.bnd.reporter
d1c336
%pom_remove_dep :biz.aQute.remote.api
d1c336
%pom_remove_dep :snakeyaml
d1c336
%pom_remove_dep :jline
d1c336
popd
d1c336
d1c336
%pom_remove_dep -r org.osgi:org.osgi.namespace.contract
d1c336
%pom_remove_dep -r org.osgi:org.osgi.namespace.extender
d1c336
%pom_remove_dep -r org.osgi:org.osgi.namespace.implementation
d1c336
%pom_remove_dep -r org.osgi:org.osgi.namespace.service
d1c336
%pom_remove_dep -r org.osgi:org.osgi.resource
d1c336
%pom_remove_dep -r org.osgi:org.osgi.service.log
d1c336
%pom_remove_dep -r org.osgi:org.osgi.service.repository
d1c336
%pom_remove_dep -r org.osgi:org.osgi.service.serviceloader
d1c336
%pom_remove_dep -r org.osgi:org.osgi.util.function
d1c336
%pom_remove_dep -r org.osgi:org.osgi.util.promise
d1c336
d1c336
%pom_xpath_remove -r pom:project/pom:dependencies/pom:dependency/pom:scope
d1c336
d1c336
%mvn_alias biz.aQute.bnd:biz.aQute.bnd :bnd biz.aQute:bnd
d1c336
%mvn_alias biz.aQute.bnd:biz.aQute.bndlib :bndlib biz.aQute:bndlib
d1c336
d1c336
%mvn_package biz.aQute.bnd:biz.aQute.bndlib bndlib
d1c336
%mvn_package biz.aQute.bnd:biz.aQute.bnd.annotation bndlib
d1c336
%mvn_package biz.aQute.bnd:aQute.libg bndlib
d1c336
%mvn_package biz.aQute.bnd:parent __noinstall
d1c336
%mvn_package biz.aQute.bnd:bnd-plugin-parent __noinstall
d1c336
d1c336
%build
d1c336
%mvn_build -- -Dproject.build.sourceEncoding=UTF-8
d1c336
d1c336
%install
d1c336
%mvn_install
d1c336
d1c336
install -d -m 755 %{buildroot}%{_sysconfdir}/ant.d
d1c336
echo "aqute-bnd slf4j/api slf4j/simple osgi-annotation osgi-core osgi-compendium" >%{buildroot}%{_sysconfdir}/ant.d/%{name}
d1c336
d1c336
%jpackage_script aQute.bnd.main.bnd "" "" aqute-bnd:slf4j/slf4j-api:slf4j/slf4j-simple:osgi-annotation:osgi-core:osgi-compendium bnd 1
d1c336
d1c336
%files -f .mfiles
d1c336
%license LICENSE
d1c336
%{_bindir}/bnd
d1c336
%config(noreplace) %{_sysconfdir}/ant.d/*
d1c336
d1c336
%files -n aqute-bndlib -f .mfiles-bndlib
d1c336
%license LICENSE
d1c336
d1c336
%files javadoc -f .mfiles-javadoc
d1c336
%license LICENSE
d1c336
d1c336
%changelog
d1c336
* Mon Dec 20 2021 Mikolaj Izdebski <mizdebsk@redhat.com> - 5.2.0-7
d1c336
- Add requires on java-devel
d1c336
d1c336
* Fri Dec 17 2021 Mattias Ellert <mattias.ellert@physics.uu.se> - 5.2.0-6
d1c336
- Add parent to biz.aQute.bnd/pom.xml (fixes [WARNING] JAR will be
d1c336
  empty - no content was marked for inclusion!)
d1c336
- Remove scope from dependencies in pom.xml files (fixes missing
d1c336
  dependencies, dependencies marked with scope provided are ignored by
d1c336
  the rpm dependency generator)
d1c336
- Drop some more commands: shell, exportreport, mbr (uses parts that
d1c336
  are not packaged)
d1c336
- Resolves: rhbz#2033709
d1c336
d1c336
* Mon Aug 09 2021 Mohan Boddu <mboddu@redhat.com> - 5.2.0-5
d1c336
- Rebuilt for IMA sigs, glibc 2.34, aarch64 flags
d1c336
  Related: rhbz#1991688
d1c336
d1c336
* Wed Jun 09 2021 Mikolaj Izdebski <mizdebsk@redhat.com> - 5.2.0-4
d1c336
- Rebuild to workaround DistroBaker issue
d1c336
d1c336
* Tue Jun 08 2021 Mikolaj Izdebski <mizdebsk@redhat.com> - 5.2.0-3
d1c336
- Bootstrap Maven for CentOS Stream 9
d1c336
d1c336
* Mon May 17 2021 Mikolaj Izdebski <mizdebsk@redhat.com> - 5.2.0-2
d1c336
- Bootstrap build
d1c336
- Non-bootstrap build
d1c336
d1c336
* Tue Jan 26 2021 Fedora Release Engineering <releng@fedoraproject.org> - 4.3.1-4
d1c336
- Rebuilt for https://fedoraproject.org/wiki/Fedora_34_Mass_Rebuild
d1c336
d1c336
* Wed Jan 20 2021 Marian Koncek <mkoncek@redhat.com> - 5.2.0-1
d1c336
- Update to upstream version 5.2.0
d1c336
d1c336
* Mon Dec 14 2020 Jerry James <loganjerry@gmail.com> - 4.3.1-3
d1c336
- Update jansi path for jansi 1.x and jline path for jline 2.x
d1c336
d1c336
* Wed Nov 25 2020 Mat Booth <mat.booth@redhat.com> - 4.3.1-2
d1c336
- Add OSGi metadata
d1c336
d1c336
* Tue Sep 29 2020 Marian Koncek <mkoncek@redhat.com> - 5.1.2-1
d1c336
- Update to upstream version 5.1.2
d1c336
d1c336
* Tue Jul 28 2020 Mat Booth <mat.booth@redhat.com> - 4.3.1-1
d1c336
- Update to latest 4.x release
d1c336
d1c336
* Mon Jul 27 2020 Mat Booth <mat.booth@redhat.com> - 4.3.0-1
d1c336
- Update to upstream version 4.3.0
d1c336
d1c336
* Mon Jul 27 2020 Fedora Release Engineering <releng@fedoraproject.org> - 3.5.0-11
d1c336
- Rebuilt for https://fedoraproject.org/wiki/Fedora_33_Mass_Rebuild
d1c336
d1c336
* Tue Jul 21 2020 Mat Booth <mat.booth@redhat.com> - 3.5.0-10
d1c336
- Fix NIO linkage error when running on Java 8 due to incorrect cross-compilation
d1c336
d1c336
* Fri Jul 10 2020 Jiri Vanek <jvanek@redhat.com> - 3.5.0-9
d1c336
- Rebuilt for JDK-11, see https://fedoraproject.org/wiki/Changes/Java11
d1c336
d1c336
* Tue Jun 23 2020 Marian Koncek <mkoncek@redhat.com> - 5.1.1-1
d1c336
- Update to upstream version 5.1.1
d1c336
d1c336
* Fri Apr 24 2020 Mikolaj Izdebski <mizdebsk@redhat.com> - 5.0.0-2
d1c336
- Disable bnd-maven-plugin
d1c336
d1c336
* Wed Jan 29 2020 Marian Koncek <mkoncek@redhat.com> - 5.0.0-1
d1c336
- Update to upstream version 5.0.0
d1c336
d1c336
* Tue Jan 28 2020 Fedora Release Engineering <releng@fedoraproject.org> - 3.5.0-8
d1c336
- Rebuilt for https://fedoraproject.org/wiki/Fedora_32_Mass_Rebuild
d1c336
d1c336
* Tue Nov 05 2019 Mikolaj Izdebski <mizdebsk@redhat.com> - 4.3.0-2
d1c336
- Mass rebuild for javapackages-tools 201902
d1c336
d1c336
* Wed Oct 09 2019 Marian Koncek <mkoncek@redhat.com> - 4.3.0-1
d1c336
- Update to upstream version 4.3.0
d1c336
d1c336
* Wed Jul 24 2019 Fedora Release Engineering <releng@fedoraproject.org> - 3.5.0-7
d1c336
- Rebuilt for https://fedoraproject.org/wiki/Fedora_31_Mass_Rebuild
d1c336
d1c336
* Thu Jul 04 2019 Marian Koncek <mkoncek@redhat.com> - 4.2.0-1
d1c336
- Update to upstream version 4.2.0
d1c336
d1c336
* Fri May 24 2019 Mikolaj Izdebski <mizdebsk@redhat.com> - 3.5.0-6
d1c336
- Mass rebuild for javapackages-tools 201901
d1c336
d1c336
* Fri Apr 12 2019 Marian Koncek <mkoncek@redhat.com> - 3.5.0-6
d1c336
- Port to OSGI 7.0.0
d1c336
d1c336
* Fri Apr 12 2019 Marian Koncek <mkoncek@redhat.com> - 3.5.0-5
d1c336
- Port to OSGI 7.0.0
d1c336
d1c336
* Thu Jan 31 2019 Fedora Release Engineering <releng@fedoraproject.org> - 3.5.0-5
d1c336
- Rebuilt for https://fedoraproject.org/wiki/Fedora_30_Mass_Rebuild
d1c336
d1c336
* Mon Jul 30 2018 Severin Gehwolf <sgehwolf@redhat.com> - 3.5.0-4
d1c336
- Add requirement on javapackages-tools for bnd script.
d1c336
d1c336
* Thu Jul 12 2018 Fedora Release Engineering <releng@fedoraproject.org> - 3.5.0-3
d1c336
- Rebuilt for https://fedoraproject.org/wiki/Fedora_29_Mass_Rebuild
d1c336
d1c336
* Wed Feb 07 2018 Fedora Release Engineering <releng@fedoraproject.org> - 3.5.0-2
d1c336
- Rebuilt for https://fedoraproject.org/wiki/Fedora_28_Mass_Rebuild
d1c336
d1c336
* Fri Oct 13 2017 Michael Simacek <msimacek@redhat.com> - 3.5.0-1
d1c336
- Update to upstream version 3.5.0
d1c336
d1c336
* Mon Oct 02 2017 Troy Dawson <tdawson@redhat.com> - 3.4.0-3
d1c336
- Cleanup spec file conditionals
d1c336
d1c336
* Sat Sep 23 2017 Mikolaj Izdebski <mizdebsk@redhat.com> - 3.4.0-2
d1c336
- Remove unneeded javadoc plugin
d1c336
d1c336
* Tue Sep 12 2017 Michael Simacek <msimacek@redhat.com> - 3.4.0-1
d1c336
- Update to upstream version 3.4.0
d1c336
d1c336
* Wed Jul 26 2017 Fedora Release Engineering <releng@fedoraproject.org> - 3.3.0-7
d1c336
- Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Mass_Rebuild
d1c336
d1c336
* Fri Feb 10 2017 Fedora Release Engineering <releng@fedoraproject.org> - 3.3.0-6
d1c336
- Rebuilt for https://fedoraproject.org/wiki/Fedora_26_Mass_Rebuild
d1c336
d1c336
* Mon Oct 10 2016 Mikolaj Izdebski <mizdebsk@redhat.com> - 3.3.0-5
d1c336
- Don't use legacy Ant artifact coordinates
d1c336
d1c336
* Mon Oct 10 2016 Mikolaj Izdebski <mizdebsk@redhat.com> - 3.3.0-4
d1c336
- Allow conditional builds without Ant tasks
d1c336
d1c336
* Mon Oct 10 2016 Mikolaj Izdebski <mizdebsk@redhat.com> - 3.3.0-3
d1c336
- Allow conditional builds without Maven plugin
d1c336
d1c336
* Thu Oct 06 2016 Michael Simacek <msimacek@redhat.com> - 3.3.0-2
d1c336
- Fix ant.d classpath
d1c336
d1c336
* Thu Sep 29 2016 Michael Simacek <msimacek@redhat.com> - 3.3.0-1
d1c336
- Update to upstream version 3.3.0
d1c336
- Build against osgi-{core,compendium}
d1c336
d1c336
* Tue Sep 27 2016 Mikolaj Izdebski <mizdebsk@redhat.com> - 3.2.0-5
d1c336
- Add felix-scr-annotations to classpath
d1c336
d1c336
* Mon Sep 26 2016 Michael Simacek <msimacek@redhat.com> - 3.2.0-4
d1c336
- Use felix-annotations
d1c336
d1c336
* Wed Sep 14 2016 Mikolaj Izdebski <mizdebsk@redhat.com> - 3.2.0-3
d1c336
- Build and install Maven plugins
d1c336
- Resolves: rhbz#1375904
d1c336
d1c336
* Wed Jun  1 2016 Mikolaj Izdebski <mizdebsk@redhat.com> - 3.2.0-2
d1c336
- Install ant.d config files
d1c336
d1c336
* Tue May 24 2016 Michael Simacek <msimacek@redhat.com> - 3.2.0-1
d1c336
- Update to upstream version 3.2.0
d1c336
d1c336
* Wed Feb 03 2016 Fedora Release Engineering <releng@fedoraproject.org> - 2.4.1-3
d1c336
- Rebuilt for https://fedoraproject.org/wiki/Fedora_24_Mass_Rebuild
d1c336
d1c336
* Fri Jul 17 2015 Michael Simacek <msimacek@redhat.com> - 2.4.1-2
d1c336
- Fix Tool header generation
d1c336
d1c336
* Wed Jul 08 2015 Michael Simacek <msimacek@redhat.com> - 2.4.1-1
d1c336
- Update to upstream version 2.4.1
d1c336
d1c336
* Wed Jun 17 2015 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.0.363-16
d1c336
- Rebuilt for https://fedoraproject.org/wiki/Fedora_23_Mass_Rebuild
d1c336
d1c336
* Thu May 14 2015 Mikolaj Izdebski <mizdebsk@redhat.com> - 0.0.363-15
d1c336
- Disable javadoc doclint
d1c336
d1c336
* Sat Jun 07 2014 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.0.363-14
d1c336
- Rebuilt for https://fedoraproject.org/wiki/Fedora_21_Mass_Rebuild
d1c336
d1c336
* Thu May 29 2014 Mikolaj Izdebski <mizdebsk@redhat.com> - 0.0.363-13
d1c336
- Use .mfiles generated during build
d1c336
d1c336
* Fri May 09 2014 Jaromir Capik <jcapik@redhat.com> - 0.0.363-12
d1c336
- Fixing ambiguous base64 class
d1c336
d1c336
* Fri May 09 2014 Gil Cattaneo <puntogil@libero.it> 0.0.363-11
d1c336
- fix rhbz#991985
d1c336
- add source compatibility with ant 1.9
d1c336
- remove and rebuild from source aQute.runtime.jar
d1c336
- update to current packaging guidelines
d1c336
d1c336
* Tue Mar 04 2014 Stanislav Ochotnicky <sochotnicky@redhat.com> - 0.0.363-10
d1c336
- Use Requires: java-headless rebuild (#1067528)
d1c336
d1c336
* Sat Aug 03 2013 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.0.363-9
d1c336
- Rebuilt for https://fedoraproject.org/wiki/Fedora_20_Mass_Rebuild
d1c336
d1c336
* Wed Feb 13 2013 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.0.363-8
d1c336
- Rebuilt for https://fedoraproject.org/wiki/Fedora_19_Mass_Rebuild
d1c336
d1c336
* Wed Jul 18 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.0.363-7
d1c336
- Rebuilt for https://fedoraproject.org/wiki/Fedora_18_Mass_Rebuild
d1c336
d1c336
* Wed Apr 25 2012 Stanislav Ochotnicky <sochotnicky@redhat.com> - 0.0.363-6
d1c336
- Get rid of unusable eclipse plugins to simplify dependencies
d1c336
d1c336
* Fri Mar 02 2012 Jaromir Capik <jcapik@redhat.com> - 0.0.363-5
d1c336
- Fixing build failures on f16 and later
d1c336
d1c336
* Thu Jan 12 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.0.363-4
d1c336
- Rebuilt for https://fedoraproject.org/wiki/Fedora_17_Mass_Rebuild
d1c336
d1c336
* Thu Sep 22 2011 Jaromir Capik <jcapik@redhat.com> - 0.0.363-3
d1c336
- Resurrection of bundled non-class files
d1c336
d1c336
* Thu Sep 22 2011 Jaromir Capik <jcapik@redhat.com> - 0.0.363-2
d1c336
- Bundled classes removed
d1c336
- jpackage-utils dependency added to the javadoc subpackage
d1c336
d1c336
* Wed Sep 21 2011 Jaromir Capik <jcapik@redhat.com> - 0.0.363-1
d1c336
- Initial version (cloned from aqute-bndlib 0.0.363)