5bd197
Name:           aqute-bnd
5bd197
Version:        4.3.0
5bd197
Release:        2%{?dist}
5bd197
Summary:        BND Tool
5bd197
# Part of jpm is under BSD, but jpm is not included in binary RPM
5bd197
License:        ASL 2.0
5bd197
URL:            http://bnd.bndtools.org/
5bd197
BuildArch:      noarch
5bd197
5bd197
Source0:        %{version}.REL.tar.gz
5bd197
# removes bundled jars from upstream tarball
5bd197
# run as:
5bd197
# ./repack-tarball.sh
5bd197
Source1:        repack-tarball.sh
5bd197
5bd197
Source2:        parent.pom
5bd197
Source3:        https://repo1.maven.org/maven2/biz/aQute/bnd/aQute.libg/%{version}/aQute.libg-%{version}.pom
5bd197
Source4:        https://repo1.maven.org/maven2/biz/aQute/bnd/biz.aQute.bnd/%{version}/biz.aQute.bnd-%{version}.pom
5bd197
Source5:        https://repo1.maven.org/maven2/biz/aQute/bnd/biz.aQute.bndlib/%{version}/biz.aQute.bndlib-%{version}.pom
5bd197
Source6:        https://repo1.maven.org/maven2/biz/aQute/bnd/biz.aQute.bnd.annotation/%{version}/biz.aQute.bnd.annotation-%{version}.pom
5bd197
5bd197
Patch0:         0001-Disable-removed-commands.patch
5bd197
Patch1:         0002-Fix-ant-compatibility.patch
5bd197
Patch2:         0003-Port-to-OSGI-7.0.0.patch
5bd197
5bd197
BuildRequires:  maven-local
5bd197
BuildRequires:  mvn(org.apache.maven.plugin-tools:maven-plugin-annotations)
5bd197
BuildRequires:  mvn(org.apache.maven.plugins:maven-plugin-plugin)
5bd197
BuildRequires:  mvn(org.apache.maven.plugins:maven-source-plugin)
5bd197
BuildRequires:  mvn(org.apache.maven.shared:maven-mapping)
5bd197
BuildRequires:  mvn(org.apache.maven:maven-artifact)
5bd197
BuildRequires:  mvn(org.apache.maven:maven-compat)
5bd197
BuildRequires:  mvn(org.apache.maven:maven-core)
5bd197
BuildRequires:  mvn(org.apache.maven:maven-plugin-api)
5bd197
BuildRequires:  mvn(org.eclipse.aether:aether-api)
5bd197
BuildRequires:  mvn(org.osgi:osgi.annotation)
5bd197
BuildRequires:  mvn(org.osgi:osgi.cmpn)
5bd197
BuildRequires:  mvn(org.osgi:osgi.core)
5bd197
BuildRequires:  mvn(org.slf4j:slf4j-api)
5bd197
BuildRequires:  mvn(org.slf4j:slf4j-simple)
5bd197
BuildRequires:  mvn(org.sonatype.plexus:plexus-build-api)
5bd197
5bd197
# Explicit javapackages-tools requires since bnd script uses
5bd197
# /usr/share/java-utils/java-functions
5bd197
Requires:       javapackages-tools
5bd197
5bd197
%description
5bd197
The bnd tool helps you create and diagnose OSGi bundles.
5bd197
The key functions are:
5bd197
- Show the manifest and JAR contents of a bundle
5bd197
- Wrap a JAR so that it becomes a bundle
5bd197
- Create a Bundle from a specification and a class path
5bd197
- Verify the validity of the manifest entries
5bd197
The tool is capable of acting as:
5bd197
- Command line tool
5bd197
- File format
5bd197
- Directives
5bd197
- Use of macros
5bd197
5bd197
%package -n aqute-bndlib
5bd197
Summary:        BND library
5bd197
5bd197
%description -n aqute-bndlib
5bd197
%{summary}.
5bd197
5bd197
%package -n bnd-maven-plugin
5bd197
Summary:        BND Maven plugin
5bd197
5bd197
%description -n bnd-maven-plugin
5bd197
%{summary}.
5bd197
5bd197
%package javadoc
5bd197
Summary:        Javadoc for %{name}
5bd197
5bd197
%description javadoc
5bd197
API documentation for %{name}.
5bd197
5bd197
%prep
5bd197
%setup -q -n bnd-%{version}.REL
5bd197
5bd197
rm gradlew*
5bd197
5bd197
%patch0 -p1
5bd197
%patch1 -p1
5bd197
%patch2 -p1
5bd197
5bd197
# the commands pull in more dependencies than we want (felix-resolver, jetty)
5bd197
rm biz.aQute.bnd/src/aQute/bnd/main/{RemoteCommand,ResolveCommand}.java
5bd197
5bd197
sed 's/@VERSION@/%{version}/' %SOURCE2 > pom.xml
5bd197
sed -i 's|${Bundle-Version}|%{version}|' biz.aQute.bndlib/src/aQute/bnd/osgi/bnd.info
5bd197
5bd197
# libg
5bd197
pushd aQute.libg
5bd197
cp -p %{SOURCE3} pom.xml
5bd197
%pom_add_parent biz.aQute.bnd:parent:%{version}
5bd197
%pom_remove_dep :org.osgi.util.function
5bd197
%pom_remove_dep :org.osgi.util.promise
5bd197
%pom_add_dep org.osgi:osgi.core
5bd197
%pom_add_dep org.osgi:osgi.cmpn
5bd197
popd
5bd197
5bd197
# bndlib.annotations
5bd197
pushd biz.aQute.bnd.annotation
5bd197
cp -p %{SOURCE6} pom.xml
5bd197
%pom_add_parent biz.aQute.bnd:parent:%{version}
5bd197
%pom_add_dep org.osgi:osgi.core
5bd197
%pom_add_dep org.osgi:osgi.cmpn
5bd197
popd
5bd197
5bd197
# bndlib
5bd197
pushd biz.aQute.bndlib
5bd197
cp -p %{SOURCE5} pom.xml
5bd197
%pom_add_parent biz.aQute.bnd:parent:%{version}
5bd197
%pom_remove_dep :org.osgi.util.function
5bd197
%pom_remove_dep :org.osgi.util.promise
5bd197
%pom_add_dep org.osgi:osgi.core
5bd197
%pom_add_dep org.osgi:osgi.cmpn
5bd197
%pom_add_dep biz.aQute.bnd:aQute.libg:%{version}
5bd197
%pom_add_dep biz.aQute.bnd:biz.aQute.bnd.annotation:%{version}
5bd197
popd
5bd197
5bd197
# bnd
5bd197
cp -r biz.aQute.bnd.exporters/src/aQute/bnd/exporter biz.aQute.bnd/src/aQute/bnd/
5bd197
pushd biz.aQute.bnd
5bd197
cp -p %{SOURCE4} pom.xml
5bd197
%pom_remove_dep :biz.aQute.resolve
5bd197
%pom_remove_dep :biz.aQute.repository
5bd197
%pom_remove_dep :biz.aQute.bnd.exporters
5bd197
%pom_remove_dep :biz.aQute.bnd.reporter
5bd197
%pom_remove_dep :biz.aQute.remote.api
5bd197
%pom_remove_dep :snakeyaml
5bd197
%pom_remove_dep :jline
5bd197
popd
5bd197
5bd197
# maven-plugins
5bd197
cp -r biz.aQute.bnd.maven/src/aQute/bnd/maven/lib/configuration maven/bnd-maven-plugin/src/main/java/aQute/bnd/maven/lib
5bd197
pushd maven
5bd197
%pom_remove_dep -r :biz.aQute.bnd.maven
5bd197
# Unavailable reactor dependency - org.osgi.impl.bundle.repoindex.cli
5bd197
%pom_disable_module bnd-indexer-maven-plugin
5bd197
# Requires unbuilt parts of bnd
5bd197
%pom_disable_module bnd-export-maven-plugin
5bd197
%pom_disable_module bnd-reporter-maven-plugin
5bd197
%pom_disable_module bnd-resolver-maven-plugin
5bd197
%pom_disable_module bnd-run-maven-plugin
5bd197
%pom_disable_module bnd-testing-maven-plugin
5bd197
# Integration tests require Internet access
5bd197
%pom_remove_plugin -r :maven-invoker-plugin
5bd197
%pom_remove_plugin -r :maven-javadoc-plugin
5bd197
5bd197
%pom_remove_plugin -r :flatten-maven-plugin
5bd197
popd
5bd197
5bd197
%mvn_alias biz.aQute.bnd:biz.aQute.bnd :bnd biz.aQute:bnd
5bd197
%mvn_alias biz.aQute.bnd:biz.aQute.bndlib :bndlib biz.aQute:bndlib
5bd197
5bd197
%mvn_package biz.aQute.bnd:biz.aQute.bndlib bndlib
5bd197
%mvn_package biz.aQute.bnd:biz.aQute.bnd.annotation bndlib
5bd197
%mvn_package biz.aQute.bnd:aQute.libg bndlib
5bd197
%mvn_package biz.aQute.bnd:bnd-maven-plugin maven
5bd197
%mvn_package biz.aQute.bnd:bnd-baseline-maven-plugin maven
5bd197
%mvn_package biz.aQute.bnd:parent __noinstall
5bd197
%mvn_package biz.aQute.bnd:bnd-plugin-parent __noinstall
5bd197
5bd197
%build
5bd197
%mvn_build -- -Dproject.build.sourceEncoding=UTF-8
5bd197
5bd197
%install
5bd197
%mvn_install
5bd197
5bd197
install -d -m 755 %{buildroot}%{_sysconfdir}/ant.d
5bd197
echo "aqute-bnd slf4j/api slf4j/simple osgi-annotation osgi-core osgi-compendium" >%{buildroot}%{_sysconfdir}/ant.d/%{name}
5bd197
5bd197
%jpackage_script aQute.bnd.main.bnd "" "" aqute-bnd:slf4j/slf4j-api:slf4j/slf4j-simple:osgi-annotation:osgi-core:osgi-compendium bnd 1
5bd197
5bd197
%files -f .mfiles
5bd197
%license LICENSE
5bd197
%{_bindir}/bnd
5bd197
%config(noreplace) %{_sysconfdir}/ant.d/*
5bd197
5bd197
%files -n aqute-bndlib -f .mfiles-bndlib
5bd197
%license LICENSE
5bd197
5bd197
%files -n bnd-maven-plugin -f .mfiles-maven
5bd197
5bd197
%files javadoc -f .mfiles-javadoc
5bd197
%license LICENSE
5bd197
5bd197
%changelog
5bd197
* Tue Nov 05 2019 Mikolaj Izdebski <mizdebsk@redhat.com> - 4.3.0-2
5bd197
- Mass rebuild for javapackages-tools 201902
5bd197
5bd197
* Wed Oct 09 2019 Marian Koncek <mkoncek@redhat.com> - 4.3.0-1
5bd197
- Update to upstream version 4.3.0
5bd197
5bd197
* Thu Jul 04 2019 Marian Koncek <mkoncek@redhat.com> - 4.2.0-1
5bd197
- Update to upstream version 4.2.0
5bd197
5bd197
* Fri May 24 2019 Mikolaj Izdebski <mizdebsk@redhat.com> - 3.5.0-6
5bd197
- Mass rebuild for javapackages-tools 201901
5bd197
5bd197
* Fri Apr 12 2019 Marian Koncek <mkoncek@redhat.com> - 3.5.0-5
5bd197
- Port to OSGI 7.0.0
5bd197
5bd197
* Mon Jul 30 2018 Severin Gehwolf <sgehwolf@redhat.com> - 3.5.0-4
5bd197
- Add requirement on javapackages-tools for bnd script.
5bd197
5bd197
* Thu Jul 12 2018 Fedora Release Engineering <releng@fedoraproject.org> - 3.5.0-3
5bd197
- Rebuilt for https://fedoraproject.org/wiki/Fedora_29_Mass_Rebuild
5bd197
5bd197
* Wed Feb 07 2018 Fedora Release Engineering <releng@fedoraproject.org> - 3.5.0-2
5bd197
- Rebuilt for https://fedoraproject.org/wiki/Fedora_28_Mass_Rebuild
5bd197
5bd197
* Fri Oct 13 2017 Michael Simacek <msimacek@redhat.com> - 3.5.0-1
5bd197
- Update to upstream version 3.5.0
5bd197
5bd197
* Mon Oct 02 2017 Troy Dawson <tdawson@redhat.com> - 3.4.0-3
5bd197
- Cleanup spec file conditionals
5bd197
5bd197
* Sat Sep 23 2017 Mikolaj Izdebski <mizdebsk@redhat.com> - 3.4.0-2
5bd197
- Remove unneeded javadoc plugin
5bd197
5bd197
* Tue Sep 12 2017 Michael Simacek <msimacek@redhat.com> - 3.4.0-1
5bd197
- Update to upstream version 3.4.0
5bd197
5bd197
* Wed Jul 26 2017 Fedora Release Engineering <releng@fedoraproject.org> - 3.3.0-7
5bd197
- Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Mass_Rebuild
5bd197
5bd197
* Fri Feb 10 2017 Fedora Release Engineering <releng@fedoraproject.org> - 3.3.0-6
5bd197
- Rebuilt for https://fedoraproject.org/wiki/Fedora_26_Mass_Rebuild
5bd197
5bd197
* Mon Oct 10 2016 Mikolaj Izdebski <mizdebsk@redhat.com> - 3.3.0-5
5bd197
- Don't use legacy Ant artifact coordinates
5bd197
5bd197
* Mon Oct 10 2016 Mikolaj Izdebski <mizdebsk@redhat.com> - 3.3.0-4
5bd197
- Allow conditional builds without Ant tasks
5bd197
5bd197
* Mon Oct 10 2016 Mikolaj Izdebski <mizdebsk@redhat.com> - 3.3.0-3
5bd197
- Allow conditional builds without Maven plugin
5bd197
5bd197
* Thu Oct 06 2016 Michael Simacek <msimacek@redhat.com> - 3.3.0-2
5bd197
- Fix ant.d classpath
5bd197
5bd197
* Thu Sep 29 2016 Michael Simacek <msimacek@redhat.com> - 3.3.0-1
5bd197
- Update to upstream version 3.3.0
5bd197
- Build against osgi-{core,compendium}
5bd197
5bd197
* Tue Sep 27 2016 Mikolaj Izdebski <mizdebsk@redhat.com> - 3.2.0-5
5bd197
- Add felix-scr-annotations to classpath
5bd197
5bd197
* Mon Sep 26 2016 Michael Simacek <msimacek@redhat.com> - 3.2.0-4
5bd197
- Use felix-annotations
5bd197
5bd197
* Wed Sep 14 2016 Mikolaj Izdebski <mizdebsk@redhat.com> - 3.2.0-3
5bd197
- Build and install Maven plugins
5bd197
- Resolves: rhbz#1375904
5bd197
5bd197
* Wed Jun  1 2016 Mikolaj Izdebski <mizdebsk@redhat.com> - 3.2.0-2
5bd197
- Install ant.d config files
5bd197
5bd197
* Tue May 24 2016 Michael Simacek <msimacek@redhat.com> - 3.2.0-1
5bd197
- Update to upstream version 3.2.0
5bd197
5bd197
* Wed Feb 03 2016 Fedora Release Engineering <releng@fedoraproject.org> - 2.4.1-3
5bd197
- Rebuilt for https://fedoraproject.org/wiki/Fedora_24_Mass_Rebuild
5bd197
5bd197
* Fri Jul 17 2015 Michael Simacek <msimacek@redhat.com> - 2.4.1-2
5bd197
- Fix Tool header generation
5bd197
5bd197
* Wed Jul 08 2015 Michael Simacek <msimacek@redhat.com> - 2.4.1-1
5bd197
- Update to upstream version 2.4.1
5bd197
5bd197
* Wed Jun 17 2015 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.0.363-16
5bd197
- Rebuilt for https://fedoraproject.org/wiki/Fedora_23_Mass_Rebuild
5bd197
5bd197
* Thu May 14 2015 Mikolaj Izdebski <mizdebsk@redhat.com> - 0.0.363-15
5bd197
- Disable javadoc doclint
5bd197
5bd197
* Sat Jun 07 2014 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.0.363-14
5bd197
- Rebuilt for https://fedoraproject.org/wiki/Fedora_21_Mass_Rebuild
5bd197
5bd197
* Thu May 29 2014 Mikolaj Izdebski <mizdebsk@redhat.com> - 0.0.363-13
5bd197
- Use .mfiles generated during build
5bd197
5bd197
* Fri May 09 2014 Jaromir Capik <jcapik@redhat.com> - 0.0.363-12
5bd197
- Fixing ambiguous base64 class
5bd197
5bd197
* Fri May 09 2014 Gil Cattaneo <puntogil@libero.it> 0.0.363-11
5bd197
- fix rhbz#991985
5bd197
- add source compatibility with ant 1.9
5bd197
- remove and rebuild from source aQute.runtime.jar
5bd197
- update to current packaging guidelines
5bd197
5bd197
* Tue Mar 04 2014 Stanislav Ochotnicky <sochotnicky@redhat.com> - 0.0.363-10
5bd197
- Use Requires: java-headless rebuild (#1067528)
5bd197
5bd197
* Sat Aug 03 2013 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.0.363-9
5bd197
- Rebuilt for https://fedoraproject.org/wiki/Fedora_20_Mass_Rebuild
5bd197
5bd197
* Wed Feb 13 2013 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.0.363-8
5bd197
- Rebuilt for https://fedoraproject.org/wiki/Fedora_19_Mass_Rebuild
5bd197
5bd197
* Wed Jul 18 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.0.363-7
5bd197
- Rebuilt for https://fedoraproject.org/wiki/Fedora_18_Mass_Rebuild
5bd197
5bd197
* Wed Apr 25 2012 Stanislav Ochotnicky <sochotnicky@redhat.com> - 0.0.363-6
5bd197
- Get rid of unusable eclipse plugins to simplify dependencies
5bd197
5bd197
* Fri Mar 02 2012 Jaromir Capik <jcapik@redhat.com> - 0.0.363-5
5bd197
- Fixing build failures on f16 and later
5bd197
5bd197
* Thu Jan 12 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.0.363-4
5bd197
- Rebuilt for https://fedoraproject.org/wiki/Fedora_17_Mass_Rebuild
5bd197
5bd197
* Thu Sep 22 2011 Jaromir Capik <jcapik@redhat.com> - 0.0.363-3
5bd197
- Resurrection of bundled non-class files
5bd197
5bd197
* Thu Sep 22 2011 Jaromir Capik <jcapik@redhat.com> - 0.0.363-2
5bd197
- Bundled classes removed
5bd197
- jpackage-utils dependency added to the javadoc subpackage
5bd197
5bd197
* Wed Sep 21 2011 Jaromir Capik <jcapik@redhat.com> - 0.0.363-1
5bd197
- Initial version (cloned from aqute-bndlib 0.0.363)