139 lines
6.9 KiB
Diff
139 lines
6.9 KiB
Diff
--- org.eclipse.tycho-tycho-1.6.0/tycho-packaging-plugin/src/main/java/org/eclipse/tycho/packaging/PackageFeatureMojo.java 2023-09-05 17:53:07.666513409 +0200
|
|
+++ org.eclipse.tycho-tycho-1.6.0/tycho-packaging-plugin/src/main/java/org/eclipse/tycho/packaging/PackageFeatureMojo.java 2023-09-05 18:32:09.064828291 +0200
|
|
@@ -30,7 +30,6 @@
|
|
import org.apache.maven.plugins.annotations.Mojo;
|
|
import org.apache.maven.plugins.annotations.Parameter;
|
|
import org.apache.maven.plugins.annotations.ResolutionScope;
|
|
-import org.codehaus.plexus.archiver.Archiver;
|
|
import org.codehaus.plexus.archiver.FileSet;
|
|
import org.codehaus.plexus.archiver.jar.JarArchiver;
|
|
import org.codehaus.plexus.component.repository.exception.ComponentLookupException;
|
|
@@ -240,7 +239,7 @@
|
|
}
|
|
|
|
private void assembleDeployableFeature() throws MojoExecutionException {
|
|
- UpdateSiteAssembler assembler = new UpdateSiteAssembler(session, target);
|
|
+ UpdateSiteAssembler assembler = new UpdateSiteAssembler(plexus, target);
|
|
getDependencyWalker().walk(assembler);
|
|
}
|
|
|
|
@@ -258,7 +257,7 @@
|
|
|
|
private JarArchiver getJarArchiver() throws MojoExecutionException {
|
|
try {
|
|
- return (JarArchiver) plexus.lookup(Archiver.ROLE, "jar");
|
|
+ return plexus.lookup(JarArchiver.class, "jar");
|
|
} catch (ComponentLookupException e) {
|
|
throw new MojoExecutionException("Unable to get JarArchiver", e);
|
|
}
|
|
--- org.eclipse.tycho-tycho-1.6.0/tycho-packaging-plugin/src/main/java/org/eclipse/tycho/packaging/ProductAssembler.java 2023-09-05 17:53:07.666513409 +0200
|
|
+++ org.eclipse.tycho-tycho-1.6.0/tycho-packaging-plugin/src/main/java/org/eclipse/tycho/packaging/ProductAssembler.java 2023-09-05 18:27:45.999431261 +0200
|
|
@@ -12,7 +12,7 @@
|
|
|
|
import java.io.File;
|
|
|
|
-import org.apache.maven.execution.MavenSession;
|
|
+import org.codehaus.plexus.PlexusContainer;
|
|
import org.eclipse.tycho.core.PluginDescription;
|
|
import org.eclipse.tycho.core.osgitools.BundleReader;
|
|
import org.eclipse.tycho.core.osgitools.OsgiManifest;
|
|
@@ -27,9 +27,9 @@
|
|
|
|
private final BundleReader manifestReader;
|
|
|
|
- public ProductAssembler(MavenSession session, BundleReader manifestReader, File target,
|
|
+ public ProductAssembler(PlexusContainer plexus, BundleReader manifestReader, File target,
|
|
TargetEnvironment environment) {
|
|
- super(session, target);
|
|
+ super(plexus, target);
|
|
this.manifestReader = manifestReader;
|
|
setUnpackPlugins(true);
|
|
setUnpackFeatures(true);
|
|
--- org.eclipse.tycho-tycho-1.6.0/tycho-packaging-plugin/src/main/java/org/eclipse/tycho/packaging/ProductExportMojo.java 2023-09-05 17:53:07.666513409 +0200
|
|
+++ org.eclipse.tycho-tycho-1.6.0/tycho-packaging-plugin/src/main/java/org/eclipse/tycho/packaging/ProductExportMojo.java 2023-09-05 18:31:24.944482180 +0200
|
|
@@ -152,7 +152,7 @@
|
|
generateConfigIni(environment, targetEclipse);
|
|
includeRootFiles(environment, targetEclipse);
|
|
|
|
- ProductAssembler assembler = new ProductAssembler(session, manifestReader, targetEclipse, environment);
|
|
+ ProductAssembler assembler = new ProductAssembler(plexus, manifestReader, targetEclipse, environment);
|
|
assembler.setIncludeSources(includeSources);
|
|
getDependencyWalker(environment).walk(assembler);
|
|
|
|
@@ -176,7 +176,7 @@
|
|
includeRootFiles(environment, targetEclipse);
|
|
}
|
|
|
|
- ProductAssembler assembler = new ProductAssembler(session, manifestReader, targetEclipse, null);
|
|
+ ProductAssembler assembler = new ProductAssembler(plexus, manifestReader, targetEclipse, null);
|
|
assembler.setIncludeSources(includeSources);
|
|
if (forcePackedDependencies) {
|
|
assembler.setUnpackFeatures(false);
|
|
@@ -381,7 +381,7 @@
|
|
private void createProductArchive(File target, String classifier) throws MojoExecutionException {
|
|
ZipArchiver zipper;
|
|
try {
|
|
- zipper = (ZipArchiver) plexus.lookup(ZipArchiver.ROLE, "zip");
|
|
+ zipper = plexus.lookup(ZipArchiver.class, "zip");
|
|
} catch (ComponentLookupException e) {
|
|
throw new MojoExecutionException("Unable to resolve ZipArchiver", e);
|
|
}
|
|
--- org.eclipse.tycho-tycho-1.6.0/tycho-packaging-plugin/src/main/java/org/eclipse/tycho/packaging/UpdateSiteAssembler.java 2023-09-05 17:53:07.666513409 +0200
|
|
+++ org.eclipse.tycho-tycho-1.6.0/tycho-packaging-plugin/src/main/java/org/eclipse/tycho/packaging/UpdateSiteAssembler.java 2023-09-05 18:31:24.944482180 +0200
|
|
@@ -19,7 +19,7 @@
|
|
import java.net.URL;
|
|
import java.util.Map;
|
|
|
|
-import org.apache.maven.execution.MavenSession;
|
|
+import org.codehaus.plexus.PlexusContainer;
|
|
import org.codehaus.plexus.archiver.ArchiverException;
|
|
import org.codehaus.plexus.archiver.zip.ZipArchiver;
|
|
import org.codehaus.plexus.archiver.zip.ZipUnArchiver;
|
|
@@ -45,7 +45,7 @@
|
|
|
|
public static final String FEATURES_DIR = "features/";
|
|
|
|
- private final MavenSession session;
|
|
+ private final PlexusContainer session;
|
|
|
|
private final File target;
|
|
|
|
@@ -63,7 +63,7 @@
|
|
*/
|
|
private boolean unpackFeatures;
|
|
|
|
- public UpdateSiteAssembler(MavenSession session, File target) {
|
|
+ public UpdateSiteAssembler(PlexusContainer session, File target) {
|
|
this.session = session;
|
|
this.target = target;
|
|
}
|
|
@@ -184,7 +184,7 @@
|
|
ZipUnArchiver unzip;
|
|
FileLockService fileLockService;
|
|
try {
|
|
- unzip = (ZipUnArchiver) session.lookup(ZipUnArchiver.ROLE, "zip");
|
|
+ unzip = session.lookup(ZipUnArchiver.class, "zip");
|
|
fileLockService = (FileLockService) session.lookup(FileLockService.class.getName());
|
|
} catch (ComponentLookupException e) {
|
|
throw new RuntimeException("Could not lookup required component", e);
|
|
@@ -244,7 +244,7 @@
|
|
private void packDir(File sourceDir, File targetZip) {
|
|
ZipArchiver archiver;
|
|
try {
|
|
- archiver = (ZipArchiver) session.lookup(ZipArchiver.ROLE, "zip");
|
|
+ archiver = session.lookup(ZipArchiver.class, "zip");
|
|
} catch (ComponentLookupException e) {
|
|
throw new RuntimeException("Unable to resolve ZipArchiver", e);
|
|
}
|
|
--- org.eclipse.tycho-tycho-1.6.0/tycho-packaging-plugin/src/main/java/org/eclipse/tycho/packaging/UpdateSiteMojo.java 2023-09-05 17:53:07.666513409 +0200
|
|
+++ org.eclipse.tycho-tycho-1.6.0/tycho-packaging-plugin/src/main/java/org/eclipse/tycho/packaging/UpdateSiteMojo.java 2023-09-05 18:27:45.999431261 +0200
|
|
@@ -52,7 +52,7 @@
|
|
try {
|
|
UpdateSite site = UpdateSite.read(new File(basedir, UpdateSite.SITE_XML));
|
|
|
|
- UpdateSiteAssembler assembler = new UpdateSiteAssembler(session, target);
|
|
+ UpdateSiteAssembler assembler = new UpdateSiteAssembler(plexus, target);
|
|
if (inlineArchives) {
|
|
assembler.setArchives(site.getArchives());
|
|
}
|