Alex Zylman
Alex Zylman

Reputation: 920

Adding an internal library to eclipse

I'm trying to add some JARs to an Eclipse project. It used to be working, but now it's not. Previously I'd just put the JARs in /war/WEB-INF/lib (it's a Google App Engine project), then refresh the Package Explorer in Eclipse and they would show up. Then I could just right-click and choose "Add to build path" and it would add. Now, for some reason, when I refresh Package Explorer some of the JARs in the folder aren't showing up.

Is there a maximum amount of JARs that Eclipse will allow me to add? (I'm at 18 currently).

Otherwise, is there some other way that I can add these?

This is with Eclipse Indigo.

Upvotes: 1

Views: 2513

Answers (2)

Aaron Digulla
Aaron Digulla

Reputation: 328840

Is there a maximum amount of JARs that Eclipse will allow me to add?

No. You're probably copying the JARs to a different folder than you expect.

To check, right click the lib folder -> properties -> select the value for "Location" (it looks like a label but you can click into it and select the text with the mouse or right mouse button -> "Select All" or click into it and Ctrl+ACtrl+C)

Now try the path in a shell or explorer to see whether it contains what you think.

If the path is correct, try to restart Eclipse.

You might also want to activate the "refresh" preferences (first few items in "Workspace") so you don't have to refresh for folder manually all the time.

Upvotes: 2

dogbane
dogbane

Reputation: 274878

Here is another way you can add jars to your build path.

  • Right click your project and select Properties
  • In the Properties dialog, go to Java Build Path
  • In the Libraries tab you can use Add JARs or Add External JARs to add a jar to the build path

Upvotes: 0

Related Questions