JimmyD
JimmyD

Reputation: 2759

Eclipse E4 application does not build correctly

I have an E4 application that contains two different plugins. The second plugin holds all my shared models and those models are used in my first plugin.

When building and starting the application using Eclipse run functionality everything works fine. All the classes in the second plugin are found and use by the first plugin.

Now when I export the full application into an executable. The export itself doesn't give any errors but when starting my application it throws errors that the classes in the second plugin cannot be found. When I check the exported jar of the second plugin I can only find the source code in the jar, not the builded class files itself.

Are there some steps to also include the class files to the second plugin jar?

My build.properties of my second plugin looks like:

source.. = src/
bin.includes = META-INF/,\
               libs/hibernate-c3p0-5.1.1.Final.jar,\
               libs/hibernate-commons-annotations-5.0.1.Final.jar,\
               libs/hibernate-core-5.1.1.Final.jar,\
               libs/hibernate-java8-5.1.1.Final.jar,\
               libs/hibernate-jpa-2.1-api-1.0.0.Final.jar,\
               libs/lombok.jar,\
               libs/logback-core-1.1.7.jar,\
               libs/slf4j-api-1.7.21.jar,\
               libs/jboss-logging-3.3.0.Final.jar,\
               libs/jta-1.1.jar,\
               libs/javassist-3.21.0-GA.jar

Upvotes: 0

Views: 36

Answers (1)

greg-449
greg-449

Reputation: 111217

Assuming you have code in a source directory you need to have a . in the bin.includes to include that code in the build:

source.. = src/
bin.includes = META-INF/,\
               .,\
               libs/hibernate-c3p0-5.1.1.Final.jar,\
               ..... other libs ....

The build.properties is only used when doing the RCP build so you don't get an error for this when you run your RCP from within Eclipse.

Upvotes: 1

Related Questions