1

Already tried

  1. Can I convert eclipse source folders into packages?
  2. Eclipse Open declaration in Java project (results in 30,000+ compile errors)

The problem

I got Guava source by running at the command line (got guava-20.0-SNAPSHOT):

git clone --depth=1 https://github.com/google/guava.git Guava

Ran

pushd Guava
mvn install -DskipTests -Dmaven.javadoc.skip=true

from the command line successfully.

Then in Eclipse I did File > Import... > Existing Maven Project (Add project(s) to working set was checked). Everything seemed to work fine, but then when I open a file, click on a method name and press F3 ("Open Declaration") to go to the declaration of the method, I get the following error:

Problems opening an editor

Reason:
Guava does not exist

["Guava" is the Eclipse project name.]

Looks like Eclipse didn't build the project and is therefore unable to trace the source code. Can anybody tell me the proper way to import Guava code into Eclipse?

Configuration:

  • Eclipse Mars (4.5.1)
  • M2E
  • Windows 7
Community
  • 1
  • 1
markvgti
  • 4,321
  • 7
  • 40
  • 62
  • Perhaps this may be some help: http://stackoverflow.com/questions/4648911/how-to-add-guava-to-eclipse-project – Jack Zach Tibbles Jan 15 '16 at 10:21
  • Can you try right clicking on the project, going to Maven and then to do "Update Project" – Ferrybig Jan 15 '16 at 10:40
  • @JackZachTibbles That is for adding the Guava jars to a project. What I am trying to do is install/use Guava as an Eclipse project so that I can conveniently browse its code, build it, may modify and submit patches etc. – markvgti Jan 15 '16 at 10:56
  • @Ferrybig unfortunately that doesn't work either. I had already tried that. – markvgti Jan 15 '16 at 10:56

0 Answers0