Sargon1
Sargon1

Reputation: 874

"build path entries missing" in an imported Eclipse project - how to solve properly?

I received an Eclipse project that I'm supposed to open and modify. However, upon importing it, I found out that it's riddled with "cannot resolve symbol" errors and that a lot of jars that it needs are missing: enter image description here

So far as I understand, the project needs a bunch of stuff from frameworks like Spring or Hibernate, but for some reason it isn't where Eclipse expects them to be. Grabbing the jars one by one and putting them in the directories specified is obviously not a good idea, and since the jars have version numbers, simply installing the frameworks and hoping it will work seems like a long shot.

So what's the correct procedure to solve this? These has to be some elegant, clean way to grab and install all that stuff.

Upvotes: 0

Views: 1615

Answers (2)

Francois Marot
Francois Marot

Reputation: 1195

Judging by the path of the missing libs, they are supposed to be in you home/.gradle folder. So I suppose that your project is not a basic Eclipse project but more a Gradle project that you should import in Eclipse as such.

So when you import your project, do not select "import existing eclipse project" but "import existing Gradle project" (or similar). I think Eclipse Gradle is quite recent so make sure you have it before importing the project (if I remember correctly, Gradle in Eclipse is referenced as "BuildShip").

Upvotes: 2

Brod
Brod

Reputation: 1455

Your project appears to be a Gradle project. Gradle is a build and dependency management tool. There is a Gradle eclipse plugin. You need to run a task from the build.gradle. For a quick overview you can look at this beginner's tutorial. http://www.mkyong.com/spring-mvc/gradle-spring-mvc-web-project-example/

Upvotes: 1

Related Questions