How to have sbt recognize dependencies from eclipse? - eclipse

I search some informations about the faisability of the exact inverse protocol described into this popular question.
Using SBT, i want to compile and/or generate a release of an already existing software actively developed with Eclipse and Plug-in Development Environment (PDE) of Eclipse.
Users want to conserve the eclipse GUI tools to define dependencies for each plugins. But we also need a console tool like SBT. Do you think it exists some tools which can generate an SBT project based on plug-in dependencies written using eclipse PDE systems ?
I see that tycho plugin for eclipse can generate maven file, is it possible using SBT and IVY repository ( don't want .pom :( ) ?

Related

Using maven generated sources in Eclipse

I have an application made up of a number of maven projects. I work on it in Eclipse. Some of the projects use Maven plugins to generate stub classes for web services etc.
When i import the projects into a new workspace I have to issue a maven generate sources command followed by attach source folders to build path on each project. The application i work on has more than 5-6 projects which require these steps.
Is there a plugin I can install in Eclipse to pick up the generated sources, or even one that generates the sources and updates the build path to save the manual steps?
I'm pretty sure the m2e plugin takes care of this automatically. m2e is included in the primary Java and Java EE packages of recent Eclipse versions, so you probably already have it. If you right-click on your project, and there is a Maven submenu, then the project is already managed by m2e. Otherwise, right-click and choose Configure > Convert to Maven project.
Well, it depends on exact maven plugin you are using.
generate sources
Before I considered that m2e connector would be needed for any non common plugin, like generator. But I came recently on some plugins (1), that do it without special m2e connector.
attach source folders to build path
For this part check build-helper-maven-plugin and answer to M2E and having maven generated source folders as eclipse source folders

What is a "build manager" for scala in the scala ide extensions for Eclipse?

In Eclipse in Preferences -> Scala -> Compiler -> Build manager, I can select a "buildmanager." What is the difference between "refined" and "sbt"?
Also, is this some method to integrate an sbt build file into the Eclipse IDE?
ScalaIDE has two build managers, basically they are interfaces between the eclipse model and the scala compiler, they have to do things like work out which resources need re-compiling and how that affects dependent code. Refined is a refined version of the original interface and sbt is, well, sbt.
SBT is the default now, and I expect refined will go away at some point.
Unfortunately the build manager is very much under the hood. There is no real eclipse project->sbt integration yet. There is an eclipse plugin for sbt which allows you to generate eclipse project files but no tight integration from an eclipse project to sbt akin to IvyDE or m2e.
You can use sbt deliver-local to create an ivy file of dependencies, and use IvyDE to keep your classpath containers up to date - that's about as good as it gets at the moment.
I wouldn't be surprised to see this situation improve though - check out the roadmap.

Want to use both older and newer version of ant plugin in eclipse for two different projects

I want to use two versions of ant plugin in eclipse for two different projects. Both versions are available in the plugins folder of my Eclipse. But I'm able to see only the latest version of ant plug-in when I'm trying to add it in the plug-in dependencies in Manifest.MF file. Please help me with this.
You can try to import both of ant plug-ins into your Eclipse workspace. Then you can let your projects depend on any version of ant for your development.
For building or releasing process, you can use Tycho to define a target platform to include both of them.

Question on "Converting Maven project of Mahout into Eclipse project"

While installing the open-source software like Mahout, I read some notes like
Convert Maven project of Mahout into Eclipse project
What does this mean? What's the difference between a Maven project and Eclipse project?
Install Maven if you haven't already done it.
Enter the command prompt or a shell and navigate to the directory where the Mahout is located (there's a pom.xml file). Type the command:
mvn eclipse:eclipse
which will create project files for Eclipse and open the project in Eclipse.
No conversion is needed. Eclipse supports Maven projects, and vice-versa.
Difference between these two projects yield from the difference of the tools. Eclipse is an IDE and Maven is a build tool. In fact, IDE is a superset of a build tool. That's why Eclipse may use Maven for building. Common properties between the projects relate to how the build is being done and Eclipse has a set of properties aimed to persist the state between programming sessions.

Getting a RCP feature to export to a p2 site that supports multiple platforms using Buckminster

I have a simple RCP Plugin (with a product) and I want it to run in atleast Linux and Windows (32 and 64bit). I have a product that contains a Feature from which buckminster uses to create the p2.site. (I only use a build.properties and buckminster.properties files, no *.cspec and *.rmap files, since these probably get generated by buckminster from the RCP product/feature files).
My problem is that my feature has a link to the 64bit linux swt plugin (I'm running 64bit linux) but if I add references to the windows swt plugins to my RCP .product the buckminster build fails to resolve these plugins and then does not export the p2.site correctly.
How do I get buckminster to build the p2 site by looking at the dependencies of my RCP .product file and if it doesn't resolve the win32 or win64 swt libraries from my workspace that it will look else where for these dependencies?
I like the idea of buckminster determining my project dependencies from my .product file so I don't have to keep a .cspec and a .product file in sync, when I make changes to my project's dependencies. If the dependencies are not found on my workspace then I want buckminster to find the missing dependencies (could be all of them if running from Hudson server) from "maybe" a .rmap etc
You have to execute your site.p2 target several times, to provide a build for each platform.
See the tutorial on the Eclipse wiki or on Ralf Ebert's blog about more specific details.