Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 184838 - Export of Plugin from MANIFEST.MF not working
Summary: Export of Plugin from MANIFEST.MF not working
Status: RESOLVED DUPLICATE of bug 114779
Alias: None
Product: PDE
Classification: Eclipse Project
Component: UI (show other bugs)
Version: 3.3   Edit
Hardware: PC Windows XP
: P3 major (vote)
Target Milestone: ---   Edit
Assignee: PDE-UI-Inbox CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2007-05-01 07:26 EDT by Benjamin Pasero CLA
Modified: 2007-05-01 14:24 EDT (History)
1 user (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Benjamin Pasero CLA 2007-05-01 07:26:02 EDT
Eclipse 3.3 M5

I am trying to export org.eclipse.swt using the Export Wizard from the manifest.mf and the result is a 12kb JAR not including any classes. This worked before (not sure if it was with M4).

Ben
Comment 1 Benjamin Pasero CLA 2007-05-01 07:35:18 EDT
Using a recent IBuild I got this btw:

java.lang.IllegalArgumentException
at java.net.URI.create(Unknown Source)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at org.apache.tools.ant.launch.Locator.fromURI(Locator.java:162)
at org.apache.tools.ant.launch.Locator.getResourceSource(Locator.java:119)
at org.apache.tools.ant.launch.Locator.getClassSource(Locator.java:90)
at org.apache.tools.ant.Project.setAntLib(Project.java:313)
at org.apache.tools.ant.Project.initProperties(Project.java:309)
at org.apache.tools.ant.Project.init(Project.java:295)
at org.eclipse.ant.internal.core.ant.InternalAntRunner.run(InternalAntRunner.java:520)
at org.eclipse.ant.internal.core.ant.InternalAntRunner.run(InternalAntRunner.java:456)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at org.eclipse.ant.core.AntRunner.run(AntRunner.java:377)
at org.eclipse.pde.internal.core.exports.FeatureExportOperation.cleanup(FeatureExportOperation.java:576)
at org.eclipse.pde.internal.core.exports.FeatureBasedExportOperation.run(FeatureBasedExportOperation.java:55)
at org.eclipse.pde.internal.ui.build.FeatureExportJob.run(FeatureExportJob.java:55)
at org.eclipse.core.internal.jobs.Worker.run(Worker.java:55)
Caused by: java.net.URISyntaxException: Illegal character in path at index 18: file:/C:/Dokumente und Einstellungen/bpasero/Desktop/eclipse-SDK-I20070427-0010-win32/eclipse/plugins/org.apache.ant_1.7.0.v200704241635/lib/ant.jar
at java.net.URI$Parser.fail(Unknown Source)
at java.net.URI$Parser.checkChars(Unknown Source)
at java.net.URI$Parser.parseHierarchical(Unknown Source)
at java.net.URI$Parser.parse(Unknown Source)
at java.net.URI.<init>(Unknown Source)
... 22 more
Comment 2 Wassim Melhem CLA 2007-05-01 09:28:05 EDT
Ben, we need more information in these bug reports.

Where is SWT coming from?  is it checked out from CVS?  is it imported via the plug-in import wizard? 
Comment 3 Benjamin Pasero CLA 2007-05-01 10:27:54 EDT
Yep its directly checked out from CVS and I renamed .classpath_win32 to .classpath. Let me know if you need more info.

Ben
Comment 4 Brian Bauman CLA 2007-05-01 13:50:08 EDT
Hi Ben,

I just tried to export org.eclipse.swt and saw the same thing as you (no classes were exported).  Since swt is always a special case, I checked out the org.eclipse.swt plug-in shipped with eclipse.  I found that it did not have any classes either and infact the size of the exported jar was within a few bytes of the shipped jar.

In order to export the classes, you need to check out org.eclipse.swt.win32.win32 and go ahead and export that project also.  After looking at their custom build.xml, it appears that in order to export the win32 fragment with its code, you must also have the org.eclipse.swt plug-in in your workspace.  With both projects in the workspace, the win32 fragment successfully exports with classes and again is within a few bytes of the shipped jar's size.

If you knew this already and still believe there is a problem, please reopen the bug.
Comment 5 Benjamin Pasero CLA 2007-05-01 14:14:27 EDT
Hi Brian,

in fact, I was trying this before and it did not work. Guess what, the problem turns out to be the use of "Eclipse-PlatformFilter" in the manifest.mf. I was not trying to export the win32 version of SWT, but the Vista WPF version (which does not match my platform which is WinXP). 

At least I would expect some kind of error dialog telling me about the Export refusing to work due to this.

Thanks anyways, removing the filter makes the export work.

Ben
Comment 6 Brian Bauman CLA 2007-05-01 14:23:53 EDT
Sounds like another bug report
Comment 7 Brian Bauman CLA 2007-05-01 14:24:24 EDT

*** This bug has been marked as a duplicate of bug 114779 ***