Scala projects with Eclipse PDE Build (2)

Some time ago I wrote about how to let Ec­lipse PDE Build auto­mat­ic­ally com­pile Scala pro­jects. There­fore a spe­cial Ant script (customBuildCallbacks.xml) had to be cre­ated in the pro­ject’s root dir­ect­ory. This script looked for the Scala lib­rary and com­piler and then built the pro­ject’s source files.

This method still works. The OSGi bundles con­tain­ing the Scala lib­rary and com­piler are de­livered to­gether with the Scala IDE for Ec­lipse. This pro­ject is now not af­fil­i­ated with the EPFL any­more and is de­veloped mostly in­de­pend­ently from the Scala tool chain. Hence, the OSGi bundle names have changed and so the Ant script from my pre­vi­ous post does not work any­more.

The fol­low­ing things have to be changed:

  • The sym­bolic name of the Scala lib­rary OSGi bundle now starts with org.scala-ide.scala.library_
  • The com­piler is now provided by a bundle whose name starts with org.scala-ide.scala.compiler_
  • The Scala Ant task now resides in scala-compiler.jar which is provided by the com­piler bundle

I cre­ated a new script that can be down­loaded here:

cus­tom­Build­Call­backs.xml (4.0 KiB)


Posted by Michel Krämer
on November, 20th 2010.