Add parent to biz.aQute.bnd/pom.xml (fixes [WARNING] JAR will be

empty no content was marked for inclusion!)
Remove scope from dependencies in pom.xml files (fixes missing
  dependencies, dependencies marked with scope provided are ignored by
  the rpm dependency generator)
Drop some more commands: shell, exportreport, mbr (uses parts that
  are not packaged)
Resolves: rhbz#1985566
This commit is contained in:
Mattias Ellert 2021-08-02 20:27:19 +02:00
parent f23b6feac0
commit acbb11e36d
2 changed files with 64 additions and 25 deletions

View File

@ -1,17 +1,7 @@
From c250eb3ebbb9afb650edc080708c5e4c3cccbb78 Mon Sep 17 00:00:00 2001
From: Michael Simacek <msimacek@redhat.com>
Date: Tue, 4 Oct 2016 18:02:26 +0200
Subject: [PATCH 1/2] Disable removed commands
---
biz.aQute.bnd/src/aQute/bnd/main/bnd.java | 49 -----------------------
1 file changed, 49 deletions(-)
diff --git a/biz.aQute.bnd/src/aQute/bnd/main/bnd.java b/biz.aQute.bnd/src/aQute/bnd/main/bnd.java
index 6870935..803c6c9 100644
--- a/biz.aQute.bnd/src/aQute/bnd/main/bnd.java
+++ b/biz.aQute.bnd/src/aQute/bnd/main/bnd.java
@@ -104,7 +104,6 @@ import aQute.bnd.osgi.Resource;
diff -ur aqute-bnd-5.2.0.orig/biz.aQute.bnd/src/aQute/bnd/main/bnd.java aqute-bnd-5.2.0/biz.aQute.bnd/src/aQute/bnd/main/bnd.java
--- aqute-bnd-5.2.0.orig/biz.aQute.bnd/src/aQute/bnd/main/bnd.java 2020-10-14 22:03:53.000000000 +0200
+++ aqute-bnd-5.2.0/biz.aQute.bnd/src/aQute/bnd/main/bnd.java 2021-08-02 18:01:59.894715497 +0200
@@ -106,7 +106,6 @@
import aQute.bnd.osgi.Verifier;
import aQute.bnd.osgi.eclipse.EclipseClasspath;
import aQute.bnd.print.JarPrinter;
@ -19,11 +9,10 @@ index 6870935..803c6c9 100644
import aQute.bnd.service.Actionable;
import aQute.bnd.service.RepositoryPlugin;
import aQute.bnd.service.action.Action;
@@ -3904,54 +3903,6 @@ public class bnd extends Processor {
getInfo(profiles);
@@ -3922,54 +3921,6 @@
}
- /**
/**
- * Resolve command
- *
- * @throws Exception
@ -71,9 +60,48 @@ index 6870935..803c6c9 100644
- rc.close();
- }
-
/**
- /**
* Export a bndrun file
*/
--
2.25.4
interface ExportOptions extends ProjectWorkspaceOptions {
@@ -4424,15 +4375,6 @@
}
}
- @Description("Start an interactive shell")
- public void _shell(Shell.ShellOptions options) throws Exception {
- try (Shell shell = new Shell(this, options)) {
- shell.loop();
- } finally {
- out.println("done");
- }
- }
-
public Workspace getWorkspace() {
return workspace;
}
@@ -4479,24 +4421,6 @@
}
- @Description("Generate and export reports of a workspace, a project or of a jar.")
- public void _exportreport(ExportReportCommand.ReporterOptions options) throws Exception {
- ExportReportCommand mc = new ExportReportCommand(this);
- mc.run(options);
- getInfo(mc);
- }
-
- @Description("Maintain Maven Bnd Repository GAV files")
- public void _mbr(MbrCommand.MrOptions options) throws Exception {
- MbrCommand c = new MbrCommand(this, options);
- CommandLine cl = new CommandLine(this);
- String s = cl.subCmd(options, c);
- if (s != null) {
- out.println(s);
- }
- getInfo(c);
- }
-
@Description("Generate source code")
interface GenerateOptions extends ProjectWorkspaceOptions {

View File

@ -2,7 +2,7 @@
Name: aqute-bnd
Version: 5.2.0
Release: 3%{?dist}
Release: 4%{?dist}
Summary: BND Tool
# Part of jpm is under BSD, but jpm is not included in binary RPM
License: ASL 2.0 or EPL-2.0
@ -71,7 +71,7 @@ API documentation for %{name}.
%patch2 -p1
# the commands pull in more dependencies than we want (felix-resolver, jetty)
rm biz.aQute.bnd/src/aQute/bnd/main/{RemoteCommand,ResolveCommand}.java
rm biz.aQute.bnd/src/aQute/bnd/main/{ExportReportCommand,MbrCommand,RemoteCommand,ReporterLogger,ResolveCommand,Shell}.java
sed 's/@VERSION@/%{version}/' %SOURCE2 > pom.xml
sed -i 's|${Bundle-Version}|%{version}|' biz.aQute.bndlib/src/aQute/bnd/osgi/bnd.info
@ -80,7 +80,6 @@ sed -i 's|${Bundle-Version}|%{version}|' biz.aQute.bndlib/src/aQute/bnd/osgi/bnd
pushd aQute.libg
cp -p %{SOURCE3} pom.xml
%pom_add_parent biz.aQute.bnd:parent:%{version}
%pom_add_dep org.osgi:osgi.core
%pom_add_dep org.osgi:osgi.cmpn
popd
@ -96,7 +95,6 @@ popd
pushd biz.aQute.bndlib
cp -p %{SOURCE5} pom.xml
%pom_add_parent biz.aQute.bnd:parent:%{version}
%pom_add_dep org.osgi:osgi.core
%pom_add_dep org.osgi:osgi.cmpn
%pom_add_dep biz.aQute.bnd:aQute.libg:%{version}
%pom_add_dep biz.aQute.bnd:biz.aQute.bnd.annotation:%{version}
@ -106,6 +104,7 @@ popd
cp -r biz.aQute.bnd.exporters/src/aQute/bnd/exporter biz.aQute.bnd/src/aQute/bnd/
pushd biz.aQute.bnd
cp -p %{SOURCE4} pom.xml
%pom_add_parent biz.aQute.bnd:parent:%{version}
%pom_remove_dep :biz.aQute.resolve
%pom_remove_dep :biz.aQute.bnd.ant
%pom_remove_dep :biz.aQute.repository
@ -127,6 +126,8 @@ popd
%pom_remove_dep -r org.osgi:org.osgi.util.function
%pom_remove_dep -r org.osgi:org.osgi.util.promise
%pom_xpath_remove -r pom:project/pom:dependencies/pom:dependency/pom:scope
%mvn_alias biz.aQute.bnd:biz.aQute.bnd :bnd biz.aQute:bnd
%mvn_alias biz.aQute.bnd:biz.aQute.bndlib :bndlib biz.aQute:bndlib
@ -159,6 +160,16 @@ echo "aqute-bnd slf4j/api slf4j/simple osgi-annotation osgi-core osgi-compendium
%license LICENSE
%changelog
* 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
empty - no content was marked for inclusion!)
- Remove scope from dependencies in pom.xml files (fixes missing
dependencies, dependencies marked with scope provided are ignored by
the rpm dependency generator)
- Drop some more commands: shell, exportreport, mbr (uses parts that
are not packaged)
- Resolves: rhbz#1985566
* Wed Jul 21 2021 Fedora Release Engineering <releng@fedoraproject.org> - 5.2.0-3
- Rebuilt for https://fedoraproject.org/wiki/Fedora_35_Mass_Rebuild