Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 212228

Summary: Export plugin does not create the proper shape
Product: [Eclipse Project] PDE Reporter: Pascal Rapicault <pascal>
Component: UIAssignee: PDE-UI-Inbox <pde-ui-inbox>
Status: RESOLVED INVALID QA Contact:
Severity: normal    
Priority: P3 CC: aniefer, baumanbr, caniszczyk
Version: 3.3   
Target Milestone: ---   
Hardware: PC   
OS: Windows XP   
Whiteboard:
Attachments:
Description Flags
the result of the build none

Description Pascal Rapicault CLA 2007-12-06 22:07:34 EST
Created attachment 84701 [details]
the result of the build

I20071204-1547
When I try to export the org.eclipse.equinox.p2.engine using the export plugin wizard the plugin produced is completely bogus:
- it contains the source that I did not ask for
- it contains the binary into a folder called 'bin'
- the qualifier has not been replaced
Comment 1 Andrew Niefer CLA 2007-12-07 11:05:00 EST
I had this happen once, but could not reproduce it in the debugger and it went away after restarting.

I was guessing maybe something got messed up in the state somewhere along the line
Comment 2 Pascal Rapicault CLA 2007-12-07 11:20:41 EST
I have a workspace where I can consistently reproduce the problem even after restart.
Comment 3 Brian Bauman CLA 2008-01-10 18:51:25 EST
I found what is causing the problem, but will continue to investigate to find the actually problem.  If you remove "javax.xml.parsers" and "org.xml.sax" from the Import-Package header, everything will export correctly.  Will keep everyone posted.
Comment 4 Brian Bauman CLA 2008-01-10 19:02:21 EST
The devil is in the details :)

The problem is the specification of Execution Environments.  PDE uses the first execution environment to resolve against.  The problem is javax.xml.parsers and org.sax.xml is not available in CDC-1.1/Foundation-1.1, only J2SE-1.4.  The proper ordering is J2SE-1.4 before CDC-1.1/Foundation-1.1.

For more information on why, see the Execution Environment wiki (http://wiki.eclipse.org/index.php/Execution_Environments), specifically "Compiling against more than is required".
Comment 5 Chris Aniszczyk CLA 2008-01-10 19:08:33 EST
Brian is so smart.

Should we have PDE catch these cases via a compiler option? The specification of BREEs are quite error prone when you have cases that run on J2SE and CLDC
Comment 6 Chris Aniszczyk CLA 2008-01-10 19:20:42 EST
opened bug 214977 to make sure this stuff doesn't happen again