Bug 396330 - Export WebStart fails due to %JAVA_HOME% defined incorrectly
Summary: Export WebStart fails due to %JAVA_HOME% defined incorrectly
Status: RESOLVED WONTFIX
Alias: None
Product: PDE
Classification: Eclipse Project
Component: Build (show other bugs)
Version: 3.7   Edit
Hardware: PC Windows 7
: P3 normal (vote)
Target Milestone: ---   Edit
Assignee: pde-build-inbox CLA
QA Contact:
URL:
Whiteboard: stalebug
Keywords: helpwanted
Depends on:
Blocks:
 
Reported: 2012-12-11 16:09 EST by Dan Damon CLA
Modified: 2018-11-13 07:27 EST (History)
2 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Dan Damon CLA 2012-12-11 16:09:53 EST

    
Comment 1 Dan Damon CLA 2012-12-11 16:14:41 EST
When %JAVA_HOME% is incorrectly defined, or not at all, you cannot export a signed WebStart feature.  The message says that it cannot find jarsigner.exe, even though both the Eclipse JRE path and project Build Path are pointing at a perfectly good JDK. Unless that JDK is in the Windows Path, the export fails.

Seems to me that the JDK defined in eclips should be used rather than the Windows Path version.
Comment 2 Curtis Windatt CLA 2012-12-11 16:28:00 EST
Can you provide steps to reproduce?  Are you exporting using the PDE feature export wizard?

The PDE UI export wizard uses PDE Build to generate an ant script that runs the jar signer.  The JRE would need to be set for the ant script to run so I don't know why the signer would need to java home.
Comment 3 Andrew Niefer CLA 2012-12-12 09:35:28 EST
In this case PDE/Build is delegating to Ant's SignJar command (via the p2 jarprocessor, see org.eclipse.equinox.p2.jarprocessor/AntSignCommand).

http://ant.apache.org/manual/Tasks/signjar.html suggests it looks in the currently running jdk(jre) for the jarsigner command.  A peek at the 1.8.3 source I have shows that it consults System.getProperty("java.home") to do this.

The SignJar task does support specifying the jarsigner executable, but both pde.build and p2.jarprocessor would need to be updated to pass it through.
Comment 4 Curtis Windatt CLA 2012-12-12 10:39:53 EST
Thanks Andrew for the details.  With no active committers, this would only be implemented with a contributed patch.
Comment 5 Eclipse Genie CLA 2018-10-23 12:04:35 EDT
This bug hasn't had any activity in quite some time. Maybe the problem got resolved, was a duplicate of something else, or became less pressing for some reason - or maybe it's still relevant but just hasn't been looked at yet.

If you have further information on the current state of the bug, please add it. The information can be, for example, that the problem still occurs, that you still want the feature, that more information is needed, or that the bug is (for whatever reason) no longer relevant.

--
The automated Eclipse Genie.
Comment 6 Lars Vogel CLA 2018-11-13 07:27:12 EST
Mass change for PDE Build bugs tagged with "helpwanted". PDE build is not actively enhanced, hence I close these bugs as wontfix. Please reopen if you want to contribute a patch.