Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorCurtis Windatt2012-12-05 20:33:13 +0000
committerCurtis Windatt2012-12-05 20:33:13 +0000
commitbb7ffb8c9afc2ca6a02be93d7055f6ad4d0a3a93 (patch)
tree0c875ecc1d304cbacccd5807ee54d2150ae71ed2
parentf55c14aa55984d3a3f587e20b80c5f771d684465 (diff)
downloadeclipse.pde.ui-bb7ffb8c9afc2ca6a02be93d7055f6ad4d0a3a93.tar.gz
eclipse.pde.ui-bb7ffb8c9afc2ca6a02be93d7055f6ad4d0a3a93.tar.xz
eclipse.pde.ui-bb7ffb8c9afc2ca6a02be93d7055f6ad4d0a3a93.zip
Bug 325368 - Product export bundles JRE even when "bundle jre for thisv20121205-203313
environment" is unchecked
-rw-r--r--ui/org.eclipse.pde.core/src/org/eclipse/pde/internal/core/exports/ProductExportOperation.java37
1 files changed, 22 insertions, 15 deletions
diff --git a/ui/org.eclipse.pde.core/src/org/eclipse/pde/internal/core/exports/ProductExportOperation.java b/ui/org.eclipse.pde.core/src/org/eclipse/pde/internal/core/exports/ProductExportOperation.java
index 25ff823986..436c5b03ac 100644
--- a/ui/org.eclipse.pde.core/src/org/eclipse/pde/internal/core/exports/ProductExportOperation.java
+++ b/ui/org.eclipse.pde.core/src/org/eclipse/pde/internal/core/exports/ProductExportOperation.java
@@ -187,25 +187,32 @@ public class ProductExportOperation extends FeatureExportOperation {
}
IJREInfo jreInfo = fProduct.getJREInfo();
- for (int i = 0; i < configurations.length; i++) {
- String[] config = configurations[i];
- File vm = jreInfo != null ? jreInfo.getJVMLocation(config[0]) : null;
+ if (jreInfo != null) {
+ for (int i = 0; i < configurations.length; i++) {
+ String[] config = configurations[i];
- if (vm != null) {
-
- if (config[0].equals("macosx") && vm.getPath().startsWith(MAC_JAVA_FRAMEWORK)) { //$NON-NLS-1$
+ // Only include the JRE if product config says to do so
+ if (!jreInfo.includeJREWithProduct(config[0])) {
continue;
}
- String rootPrefix = IBuildPropertiesConstants.ROOT_PREFIX + config[0] + "." + config[1] + //$NON-NLS-1$
- "." + config[2]; //$NON-NLS-1$
- properties.put(rootPrefix + ".folder.jre", "absolute:" + vm.getAbsolutePath()); //$NON-NLS-1$ //$NON-NLS-2$
- String perms = (String) properties.get(rootPrefix + ".permissions.755"); //$NON-NLS-1$
- if (perms != null) {
- StringBuffer buffer = new StringBuffer(perms);
- buffer.append(","); //$NON-NLS-1$
- buffer.append("jre/bin/java"); //$NON-NLS-1$
- properties.put(rootPrefix + ".permissions.755", buffer.toString()); //$NON-NLS-1$
+ File vm = jreInfo.getJVMLocation(config[0]);
+ if (vm != null) {
+
+ if (config[0].equals("macosx") && vm.getPath().startsWith(MAC_JAVA_FRAMEWORK)) { //$NON-NLS-1$
+ continue;
+ }
+
+ String rootPrefix = IBuildPropertiesConstants.ROOT_PREFIX + config[0] + "." + config[1] + //$NON-NLS-1$
+ "." + config[2]; //$NON-NLS-1$
+ properties.put(rootPrefix + ".folder.jre", "absolute:" + vm.getAbsolutePath()); //$NON-NLS-1$ //$NON-NLS-2$
+ String perms = (String) properties.get(rootPrefix + ".permissions.755"); //$NON-NLS-1$
+ if (perms != null) {
+ StringBuffer buffer = new StringBuffer(perms);
+ buffer.append(","); //$NON-NLS-1$
+ buffer.append("jre/bin/java"); //$NON-NLS-1$
+ properties.put(rootPrefix + ".permissions.755", buffer.toString()); //$NON-NLS-1$
+ }
}
}
}

Back to the top