# Is it possible to build an Eclipse plugin

**URL:** <https://discuss.gradle.org/t/is-it-possible-to-build-an-eclipse-plugin/7580>\
**Category:** Old Forum Archive\
**Created:** [December 22, 2011, 9:36am UTC](https://discuss.gradle.org/t/is-it-possible-to-build-an-eclipse-plugin/7580 "2011-12-22T09:36:00Z")\
**Posts on this page:** 20\
**Page:** 1

<div class="post-metadata">

**Author:** ![HiTry](https://avatars.discourse-cdn.com/v4/letter/h/c0e974/32.png) [@HiTry](https://discuss.gradle.org/u/HiTry)\
**Post date:** [December 22, 2011, 9:36am UTC](https://discuss.gradle.org/t/is-it-possible-to-build-an-eclipse-plugin/7580/1 "2011-12-22T09:36:00Z")

</div>

Hi, I’m interested if it’s possible to build an eclipse plugin (or whole RCP application) using gradle. I’ve simple project which depends on several plugins from p2 repository. I was wondering if it’s possible to build such project using gradle.

Cheers, P

---

<div class="post-metadata">

**Author:** ![Rene](https://sea1.discourse-cdn.com/gradle/user_avatar/discuss.gradle.org/rene/32/8082_2.png) [@Rene](https://discuss.gradle.org/u/Rene)\
**Post date:** [December 24, 2011, 10:24am UTC](https://discuss.gradle.org/t/is-it-possible-to-build-an-eclipse-plugin/7580/2 "2011-12-24T10:24:00Z")

</div>

Hello P, There is no full blown gradle support for building eclipse plugins / rcp apps yet. Grégrovy Boissinot started the pdePlugin for gradle a while ago. This is a thin layer on top of the eclipse PDE build. You can find this plugin at github ([https://github.com/gboissinot/gradleplugins](https://github.com/gboissinot/gradleplugins))

regards, René

---

<div class="post-metadata">

**Author:** ![stesieber](https://sea1.discourse-cdn.com/gradle/user_avatar/discuss.gradle.org/stesieber/32/377_2.png) [@stesieber](https://discuss.gradle.org/u/stesieber)\
**Post date:** [January 25, 2012, 10:04am UTC](https://discuss.gradle.org/t/is-it-possible-to-build-an-eclipse-plugin/7580/3 "2012-01-25T10:04:00Z")

</div>

I started to look at the pdePlugin, just in case anyone else is interested, here is what I did to get the pde plugin Project in our maven Repository:

- download the latest sources (7.1.3 in my case) \* in the base gradle.build file: \*\* remove the ivy configuration (starts with org.apache.ivy.util…) \*\* replace the uploadArchives configuration with your own company settings \* do a gradle uploadArtifacts \* you can now use the plugin when after importing it with the buildscript{} element

Right now I’m trying to get the samples working, they seem to be written for Gradle 0.9-rc-1 (?). I’m using 1.0-milestone-7

---

<div class="post-metadata">

**Author:** ![Dennis\_Hubner](https://sea1.discourse-cdn.com/gradle/user_avatar/discuss.gradle.org/dennis_hubner/32/1239_2.png) [@Dennis\_Hubner](https://discuss.gradle.org/u/Dennis_Hubner)\
**Post date:** [June 12, 2012, 9:28am UTC](https://discuss.gradle.org/t/is-it-possible-to-build-an-eclipse-plugin/7580/4 "2012-06-12T09:28:00Z")

</div>

> Right now I’m trying to get the samples working

… are you still trying?

---

<div class="post-metadata">

**Author:** ![stesieber](https://sea1.discourse-cdn.com/gradle/user_avatar/discuss.gradle.org/stesieber/32/377_2.png) [@stesieber](https://discuss.gradle.org/u/stesieber)\
**Post date:** [June 12, 2012, 3:44pm UTC](https://discuss.gradle.org/t/is-it-possible-to-build-an-eclipse-plugin/7580/5 "2012-06-12T15:44:00Z")

</div>

no 🙂 it didn’t take 5 months to get it working 😉

Unfortunately I don’t have access to the sources for the next few weeks, so I can’t give you a summary of what I needed to change.

The plugin is a wrapper around the pdeBuild ant - Task. So If you’re able to run that, it shouldn’t be too much work to get it working using the plugin. This means that you can build a product.

IIRC: pde tests are not executed out of the box (Rene correct me if I’m wrong). We worked around this issue by defining a ‘normal’ Gradle build that compiles our plugins and runs all of our tests outside an OSGI - container. This worked for us because we have no gui tests and we also don’t test any OSGI - specifics.

Another downside of it is that we currently have the plugin dependencies in two places - the Manifest and in build.gradle. In order to be able to resolve our plugin dependencies, we uploaded artefacts for all plugins in our target platform to our Maven Repository (using the mvn eclipse plugin).

HTH.

---

<div class="post-metadata">

**Author:** ![carlo\_lf](https://sea1.discourse-cdn.com/gradle/user_avatar/discuss.gradle.org/carlo_lf/32/1881_2.png) [@carlo\_lf](https://discuss.gradle.org/u/carlo_lf)\
**Post date:** [August 25, 2012, 12:46pm UTC](https://discuss.gradle.org/t/is-it-possible-to-build-an-eclipse-plugin/7580/6 "2012-08-25T12:46:00Z")

</div>

Eclipse now has a Maven plugin called Tycho. I didn’t try, just read about it. I think it would be gread if Gradle had a comparable plugin.

---

<div class="post-metadata">

**Author:** ![HiTry](https://avatars.discourse-cdn.com/v4/letter/h/c0e974/32.png) [@HiTry](https://discuss.gradle.org/u/HiTry)\
**Post date:** [September 25, 2012, 10:11am UTC](https://discuss.gradle.org/t/is-it-possible-to-build-an-eclipse-plugin/7580/7 "2012-09-25T10:11:00Z")

</div>

Well I guess for now we’re stuck with Tycho.

---

<div class="post-metadata">

**Author:** ![HiTry](https://avatars.discourse-cdn.com/v4/letter/h/c0e974/32.png) [@HiTry](https://discuss.gradle.org/u/HiTry)\
**Post date:** [September 25, 2012, 10:12am UTC](https://discuss.gradle.org/t/is-it-possible-to-build-an-eclipse-plugin/7580/8 "2012-09-25T10:12:00Z")

</div>

Well I guess we have to stick with Tycho.

---

<div class="post-metadata">

**Author:** ![Pascal\_Gelinas](https://avatars.discourse-cdn.com/v4/letter/p/839c29/32.png) [@Pascal\_Gelinas](https://discuss.gradle.org/u/Pascal_Gelinas)\
**Post date:** [March 13, 2013, 3:42pm UTC](https://discuss.gradle.org/t/is-it-possible-to-build-an-eclipse-plugin/7580/9 "2013-03-13T15:42:00Z")

</div>

I’ve taken a look at the original pdePlugin and I’m in the process of bringing it in a usable state for gradle 1.3. I’ve also added a couple of features to it that I needed and I’m almost done. I’ll release the code on github in my personal repo and with a PR to Gregory for good measure.

Right now I’ve gotten the feature sample to work but can’t get the product sample to compile. I won’t try any further for product build because I don’t need it right now, but I might come back to it eventually.

---

<div class="post-metadata">

**Author:** ![Laurent\_PETIT](https://sea1.discourse-cdn.com/gradle/user_avatar/discuss.gradle.org/laurent_petit/32/1371_2.png) [@Laurent\_PETIT](https://discuss.gradle.org/u/Laurent_PETIT)\
**Post date:** [November 19, 2013, 7:52am UTC](https://discuss.gradle.org/t/is-it-possible-to-build-an-eclipse-plugin/7580/10 "2013-11-19T07:52:00Z")

</div>

Hello,

I’d like to revive this thread to know from the source what the status of building Eclipse plugins / products with Gradle is.

Thanks in advance,

–

Laurent

---

<div class="post-metadata">

**Author:** ![luke\_daley](https://sea1.discourse-cdn.com/gradle/user_avatar/discuss.gradle.org/luke_daley/32/9890_2.png) [@luke\_daley](https://discuss.gradle.org/u/luke_daley)\
**Post date:** [November 19, 2013, 7:58am UTC](https://discuss.gradle.org/t/is-it-possible-to-build-an-eclipse-plugin/7580/11 "2013-11-19T07:58:00Z")

</div>

Hi Laurent,

There’s been no change in terms of core support. You’ll have to check in with the plugins linked to above.

---

<div class="post-metadata">

**Author:** ![Rahul\_Pandey](https://avatars.discourse-cdn.com/v4/letter/r/8edcca/32.png) [@Rahul\_Pandey](https://discuss.gradle.org/u/Rahul_Pandey)\
**Post date:** [February 17, 2014, 7:09am UTC](https://discuss.gradle.org/t/is-it-possible-to-build-an-eclipse-plugin/7580/12 "2014-02-17T07:09:00Z")

</div>

HI, I am using Gradle 1.9 on which I am not able to use pdePlugin7.1.5.Getting some error NoSuchMethod allTasks(). Can you please , who used this plugin to develope eclipse plugin, guide me to use this in developing Eclipse plugin.

Thanks In advance.

---

<div class="post-metadata">

**Author:** ![Pascal\_Gelinas](https://avatars.discourse-cdn.com/v4/letter/p/839c29/32.png) [@Pascal\_Gelinas](https://discuss.gradle.org/u/Pascal_Gelinas)\
**Post date:** [February 17, 2014, 9:26pm UTC](https://discuss.gradle.org/t/is-it-possible-to-build-an-eclipse-plugin/7580/13 "2014-02-17T21:26:00Z")

</div>

I’ve forked the original pde Plugin here: [https://github.com/pgelinas/gradleplugins](https://github.com/pgelinas/gradleplugins). It is known to work with gradle 1.3, so it should work with 1.9. It’s been months since I’ve used it though, there might still be some rough edges.

---

<div class="post-metadata">

**Author:** ![Rahul\_Pandey](https://avatars.discourse-cdn.com/v4/letter/r/8edcca/32.png) [@Rahul\_Pandey](https://discuss.gradle.org/u/Rahul_Pandey)\
**Post date:** [February 20, 2014, 7:14am UTC](https://discuss.gradle.org/t/is-it-possible-to-build-an-eclipse-plugin/7580/14 "2014-02-20T07:14:00Z")

</div>

Hi Pascal, I tried with your forked pdePlugin but still not able to build my plugin using it. I have configured pdeBuild but getting failure message -

:pdeBuild FAILED FAILURE: Build failed with an exception. \* What went wrong: Execution failed for task ‘:pdeBuild’. \> No such property: jar for class: java.lang.String

Here is my configuration- pdeBuild {

def projectDir = getRootDir()

envConfigs = “linux, 3.2.0-52-generic, amd64, unix”

buildDirectory = “${projectDir}/build/work”

publishDirectory = “${projectDir}/build”

pluginsSrcDirList = ["${projectDir}/…"]

builderDir = “${projectDir}/build”

base = “/home/epeyrul/NGMM/Eclipse-RCP”

buildId = “ProductOnPluginsExample”

baseLocation = “/home/epeyrul/NGMM/Eclipse-RCP/eclipse”

eclipseLocation = “/home/epeyrul/NGMM/Eclipse-RCP/eclipse”

equinoxLauncherPluginVersion = “1.3.0.v20130327-1440”

pdeBuildPluginVersion = “8.0”

productName = “/ProductOnPluginsExample/simplemailproduct.product”

}

Please help me to build sample plugin first then I’ll try to build my plugin.

---

<div class="post-metadata">

**Author:** ![Pascal\_Gelinas](https://avatars.discourse-cdn.com/v4/letter/p/839c29/32.png) [@Pascal\_Gelinas](https://discuss.gradle.org/u/Pascal_Gelinas)\
**Post date:** [February 20, 2014, 2:23pm UTC](https://discuss.gradle.org/t/is-it-possible-to-build-an-eclipse-plugin/7580/15 "2014-02-20T14:23:00Z")

</div>

Please open an issue on the github repository with the full stack strace (gradle -s) so I can better help you. Thanks.

---

<div class="post-metadata">

**Author:** ![Andrey\_Hihlovskiy](https://sea1.discourse-cdn.com/gradle/user_avatar/discuss.gradle.org/andrey_hihlovskiy/32/201_2.png) [@Andrey\_Hihlovskiy](https://discuss.gradle.org/u/Andrey_Hihlovskiy)\
**Post date:** [May 5, 2014, 3:07pm UTC](https://discuss.gradle.org/t/is-it-possible-to-build-an-eclipse-plugin/7580/16 "2014-05-05T15:07:00Z")

</div>

Regarding original question: yes, now it is possible. Today I released new gradle plugin: Wuff version 0.0.1. It fully automates assembly of OSGi/Equinox/Eclipse-RCP/Eclipse-IDE bundles and applications.

Sources and doc: [https://github.com/akhikhl/wuff](https://github.com/akhikhl/wuff)

Wuff is available at jcenter and maven central.

---

<div class="post-metadata">

**Author:** ![carlo\_lf](https://sea1.discourse-cdn.com/gradle/user_avatar/discuss.gradle.org/carlo_lf/32/1881_2.png) [@carlo\_lf](https://discuss.gradle.org/u/carlo_lf)\
**Post date:** [May 6, 2014, 5:09pm UTC](https://discuss.gradle.org/t/is-it-possible-to-build-an-eclipse-plugin/7580/17 "2014-05-06T17:09:00Z")

</div>

After a quick reading through your wiki docs I got the impression that you did a fine work and the plugin deserves a try.

Some questions remain: - with the Gradle build using the plugin, the compiler is a regular Javac. Therefore, the compile process does not depend on the “Export-Package” definitions of the MANIFEST.MF but uses the Gradle dependencies, i.e. “compile project(:‘some.subproject’)”? - Will the plugin respect user defined entries (done in the IDE) within “plugin.xml” or “MANIFEST.MF”? This means: for the IDE developper the Gradle build scripts are fully transparent?

---

<div class="post-metadata">

**Author:** ![Andrey\_Hihlovskiy](https://sea1.discourse-cdn.com/gradle/user_avatar/discuss.gradle.org/andrey_hihlovskiy/32/201_2.png) [@Andrey\_Hihlovskiy](https://discuss.gradle.org/u/Andrey_Hihlovskiy)\
**Post date:** [May 7, 2014, 12:24pm UTC](https://discuss.gradle.org/t/is-it-possible-to-build-an-eclipse-plugin/7580/18 "2014-05-07T12:24:00Z")

</div>

Answers: 1. Wuff supports two opportunities: dependency as compile project(’:some:subproject’) and dependency as Require-Bundle in MANIFEST.MF. Require-Bundle is automatically translated to project-level dependency, as soon as project tree contains a project with given symbolic-name in manifest. 2. Wuff respects user-defined plugin.xml and manifest, yes. Although these files can be completely omitted - it will generate them as necessary.

I’ve written tutorial on converting existing Eclipse plugins and apps to Gradle/Wuff:

> **[akhikhl/wuff](https://github.com/akhikhl/wuff/wiki/Convert-existing-Eclipse-plugins-and-apps-to-Gradle)**
>
> Gradle plugin for automating assembly of OSGi/Eclipse bundles and applications - akhikhl/wuff

BTW, version 0.0.2 is out.

---

<div class="post-metadata">

**Author:** ![Andrey\_Hihlovskiy](https://sea1.discourse-cdn.com/gradle/user_avatar/discuss.gradle.org/andrey_hihlovskiy/32/201_2.png) [@Andrey\_Hihlovskiy](https://discuss.gradle.org/u/Andrey_Hihlovskiy)\
**Post date:** [May 7, 2014, 12:25pm UTC](https://discuss.gradle.org/t/is-it-possible-to-build-an-eclipse-plugin/7580/19 "2014-05-07T12:25:00Z")

</div>

Answers: 1. Wuff supports two opportunities: dependency as compile project(’:some:subproject’) and dependency as Require-Bundle in MANIFEST.MF. Require-Bundle is automatically translated to project-level dependency, as soon as project tree contains a project with given symbolic-name in manifest. 2. Wuff respects user-defined plugin.xml and manifest, yes. Although these files can be completely omitted - it will generate them as necessary.

I’ve written tutorial on converting existing Eclipse plugins and apps to Gradle/Wuff: [https://github.com/akhikhl/wuff/wiki/Convert-existing-Eclipse-plugins-and-apps-to-Gradle](https://github.com/akhikhl/wuff/wiki/Convert-existing-Eclipse-plugins-and-apps-to-Gradle)

BTW, version 0.0.2 is out.

---

<div class="post-metadata">

**Author:** ![Andrey\_Hihlovskiy](https://sea1.discourse-cdn.com/gradle/user_avatar/discuss.gradle.org/andrey_hihlovskiy/32/201_2.png) [@Andrey\_Hihlovskiy](https://discuss.gradle.org/u/Andrey_Hihlovskiy)\
**Post date:** [May 7, 2014, 12:28pm UTC](https://discuss.gradle.org/t/is-it-possible-to-build-an-eclipse-plugin/7580/20 "2014-05-07T12:28:00Z")

</div>

Documentation will be improved with these valuable details.

[Next page](https://discuss.gradle.org/t/is-it-possible-to-build-an-eclipse-plugin/7580.md?page=2)
