Paul Verest
Paul Verest

Reputation: 63872

Creating Eclipse RCP application with Lars Vogel "Eclipse Products and Deployment - Tutorial"

I am trying to create Eclipse RCP application using Eclipse 4.3.0 on Windows.

For references I took Lars Vogel article "Eclipse Products and Deployment - Tutorial" http://www.vogella.com/tutorials/EclipseProductDeployment/article.html This tutorial doesn't give any code, but I referenced it and follow to be sure something was missed. But it was. What went wrong?

I create Plugin project using Multi-page Editor wizard.

I can launch from plugin.xml and see new plugin functionality inside Eclipse IDE runtime.

Then following the Tutorial I create .product file, and Application class with generated methods (start and stop)

public class Application implements IApplication {

But when using "Launch an Eclipse application" from .product Overview, I get

!SESSION Fri Jan 10 13:22:34 CST 2014 ------------------------------------------
!ENTRY org.eclipse.equinox.launcher 4 0 2014-01-10 13:22:34.195
!MESSAGE Exception launching the Eclipse Platform:
!STACK
java.lang.ClassNotFoundException: org.eclipse.core.runtime.adaptor.EclipseStarter
    at java.net.URLClassLoader$1.run(URLClassLoader.java:366)
    at java.net.URLClassLoader$1.run(URLClassLoader.java:355)
    at java.security.AccessController.doPrivileged(Native Method)
    at java.net.URLClassLoader.findClass(URLClassLoader.java:354)
    at java.lang.ClassLoader.loadClass(ClassLoader.java:424)
    at java.lang.ClassLoader.loadClass(ClassLoader.java:357)
    at org.eclipse.equinox.launcher.Main.invokeFramework(Main.java:633)
    at org.eclipse.equinox.launcher.Main.basicRun(Main.java:591)
    at org.eclipse.equinox.launcher.Main.run(Main.java:1450)
    at org.eclipse.equinox.launcher.Main.main(Main.java:1426)

That looks similar to old Eclipse question java.lang.ClassNotFoundException: org.eclipse.core.runtime.adaptor.EclipseStarter which is not helpful.

When using "Eclipse Product export wizard", I get files inside eclipse folder. But when launching my todo.exe, there is Dialog

Java was started but returned exit code=13

I have found logs in configuration folder

!SESSION Fri Jan 10 13:46:19 CST 2014 ------------------------------------------
!ENTRY org.eclipse.equinox.launcher 4 0 2014-01-10 13:46:19.008
!MESSAGE Exception launching the Eclipse Platform:
!STACK
java.lang.RuntimeException: Could not find framework
    at org.eclipse.equinox.launcher.Main.getBootPath(Main.java:992)
    at org.eclipse.equinox.launcher.Main.basicRun(Main.java:571)
    at org.eclipse.equinox.launcher.Main.run(Main.java:1450)
    at org.eclipse.equinox.launcher.Main.main(Main.java:1426)

What went wrong?

I also looked at folloed story-like question How to make simplistic RCP application really standalone? (that is also unaswered), but it gave me no clues.

Finally when wrting this question, StackOverflow suggest me some similar (will look again)

Upvotes: 1

Views: 2219

Answers (2)

Chandrayya G K
Chandrayya G K

Reputation: 8849

This might help:

Go to run configuration of your product. Go to Plugins tab then click on "Add required plugins". Then run your product.

Edit:

Click on Run -> Run Configurations. See below

enter image description here

Upvotes: 0

greg-449
greg-449

Reputation: 111142

Perhaps the simplest way to see the setup of a RCP project is to use one of the examples provided by the New > Plug-in Project wizard.

On the second page of the wizard select This plug-in will make contributions to the UI and also Yes for Would you like to create a 3.x rich client application.

With these settings the third page of the wizard should offer three RCP examples.

Note: This creates the old style 3.x RCP as covered by the tutorials you mention, there is also the new e4 style RCP. e4 RCPs have restrictions on what existing Eclipse code you can use but have other advantages (covered in detail here).

Upvotes: 3

Related Questions