Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
Diffstat (limited to 'bundles/org.eclipse.equinox.p2.artifact.repository/src/org/eclipse/equinox/internal/p2/artifact/processors/pack200/Pack200ProcessorStep.java')
-rw-r--r--bundles/org.eclipse.equinox.p2.artifact.repository/src/org/eclipse/equinox/internal/p2/artifact/processors/pack200/Pack200ProcessorStep.java14
1 files changed, 12 insertions, 2 deletions
diff --git a/bundles/org.eclipse.equinox.p2.artifact.repository/src/org/eclipse/equinox/internal/p2/artifact/processors/pack200/Pack200ProcessorStep.java b/bundles/org.eclipse.equinox.p2.artifact.repository/src/org/eclipse/equinox/internal/p2/artifact/processors/pack200/Pack200ProcessorStep.java
index 9d4fd8580..9d85ac7ac 100644
--- a/bundles/org.eclipse.equinox.p2.artifact.repository/src/org/eclipse/equinox/internal/p2/artifact/processors/pack200/Pack200ProcessorStep.java
+++ b/bundles/org.eclipse.equinox.p2.artifact.repository/src/org/eclipse/equinox/internal/p2/artifact/processors/pack200/Pack200ProcessorStep.java
@@ -48,10 +48,18 @@ public class Pack200ProcessorStep extends AbstractBufferingStep {
@Override
public void initialize(IProvisioningAgent agent, IProcessingStepDescriptor descriptor, IArtifactDescriptor context) {
super.initialize(agent, descriptor, context);
+ boolean isJava14 = false;
+ if (System.getProperty("java.specification.version").compareTo("14") >= 0) { //$NON-NLS-1$ //$NON-NLS-2$
+ isJava14 = true;
+ }
+
if (!isEnabled()) {
IStatus status = null;
+ // Missing pack200 executable is fine on Java 14+
+ int statusCode = isJava14 ? IStatus.OK : IStatus.ERROR;
if (detailedResult) {
- status = new Status(IStatus.ERROR, Activator.ID, MirrorRequest.ARTIFACT_PROCESSING_ERROR, "Unpack facility not configured.", null); //$NON-NLS-1$
+ status = new Status(statusCode, Activator.ID, MirrorRequest.ARTIFACT_PROCESSING_ERROR,
+ "Unpack facility not configured.", null); //$NON-NLS-1$
detailedResult = true;
} else {
String[] locations = Utils.getPack200Commands("unpack200"); //$NON-NLS-1$
@@ -59,7 +67,9 @@ public class Pack200ProcessorStep extends AbstractBufferingStep {
for (String location : locations) {
locationTried.append(location).append(", "); //$NON-NLS-1$
}
- status = new Status(IStatus.ERROR, Activator.ID, MirrorRequest.ARTIFACT_PROCESSING_ERROR, "Unpack facility not configured. The locations searched for unpack200 are: " + locationTried, null); //$NON-NLS-1$
+ status = new Status(statusCode, Activator.ID, MirrorRequest.ARTIFACT_PROCESSING_ERROR,
+ "Unpack facility not configured. The locations searched for unpack200 are: " + locationTried, //$NON-NLS-1$
+ null);
}
setStatus(status);
}

Back to the top