Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 138792 - Provide a classpath container for SWT classes
Summary: Provide a classpath container for SWT classes
Status: VERIFIED DUPLICATE of bug 122527
Alias: None
Product: JDT
Classification: Eclipse Project
Component: Debug (show other bugs)
Version: 3.2   Edit
Hardware: All All
: P3 enhancement with 1 vote (vote)
Target Milestone: ---   Edit
Assignee: JDT-Debug-Inbox CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2006-04-26 19:59 EDT by Alex Blewitt CLA
Modified: 2006-04-28 09:36 EDT (History)
0 users

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Alex Blewitt CLA 2006-04-26 19:59:32 EDT
When developing a standalone SWT application (i.e. non RCP) I need to link against the SWT libraries. Normally, this involves extending the ECLIPSE_HOME environment variable and then selecting the appropriate SWT libraries that Eclipse came with, but it's then non-portable to different versions of Eclipse.

If there was an SWT classpath container that always contained the org.eclipse.swt_* and org.eclipse.swt.OS_* Jars for the platform at hand, then I could just click on the 'Add Library' (in much the same way that the JRE or plugin-dependencies are added). This could then be made available for future versions of Eclipse, and regardless what level of Eclipse (3.2.0, 3.2.1 ... 3.3.0/4.0.0) was being run against, the default platform's SWT classpath library would still be valid.

I beliee that JDT Core provides these classpath environment variables, but it's possible that it should be reassigned to another component.

Eclipse 3.2RC1a on Mac OS X 10.4.5, but applicable to any OS.
Comment 1 Alex Blewitt CLA 2006-04-26 20:01:04 EDT
NB a workaround is to create a user library to do this.
Comment 2 Philipe Mulet CLA 2006-04-27 07:01:20 EDT
Neither the JRE container, nor the PDE container do belong to JDT/Core. The same would apply to SWT container.

It should be contributed by some 3rd party who leverages SWT in IDE (I am not aware of any so far). JDT is agnostic about such library specifities.
Comment 3 Alex Blewitt CLA 2006-04-27 17:43:14 EDT
The JDT has 'Run as SWT application' as an action, so there is some implicit support from JDT to SWT applications; perhaps this is only UI though. The fact is that in order for that to make sense, the project has already had to be set up with the appropriate SWT libraries. Whilst JDT may be agnostic, the 'Run as SWT application' certainly isn't. 

Moving to JDT-UI if that's more appropriate.
Comment 4 Prashant Deva CLA 2006-04-27 20:00:15 EDT
I agree with Alex, there should be predefined user lib for swt in jdt by default
Comment 5 Olivier Thomann CLA 2006-04-27 21:10:54 EDT
'Run as SWT application' is a launching configuration.
Moving to JDT/Debug then.
Comment 6 Wassim Melhem CLA 2006-04-27 21:49:18 EDT
Darin, this is a dup of bug 122527
Comment 7 Darin Wright CLA 2006-04-27 22:24:03 EDT

*** This bug has been marked as a duplicate of 122527 ***
Comment 8 Alex Blewitt CLA 2006-04-28 09:36:16 EDT
Verified dup. People who've voted on this might like to address further attention to the bug 122527