Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Language IDEs » Java Development Tools (JDT) » How can I tell Eclipse to not include other jars on a jar dependency's classpath?
How can I tell Eclipse to not include other jars on a jar dependency's classpath? [message #762031] Wed, 07 December 2011 08:04 Go to next message
J.-P. Pellet is currently offline J.-P. Pellet
Messages: 71
Registered: July 2009
Member
I have the following setup:

/mylibs/a.jar
/mylibs/b.jar

and an Eclipse project that should have a.jar on its classpath for
building. Unfortunately — something that I cannot change — a.jar has a
manifest with an entry like this:

Class-Path: b.jar

so Eclipse also automatically adds b.jar in the list of referenced
libraries — except I don't want it.

How can I prevent Eclipse to add b.jar from being added to the list of
libraries?

TIA,
J.-P.
Re: How can I tell Eclipse to not include other jars on a jar dependency's classpath? [message #762037 is a reply to message #762031] Wed, 07 December 2011 08:12 Go to previous messageGo to next message
Thomas Schindl is currently offline Thomas Schindl
Messages: 5257
Registered: July 2009
Senior Member
You can set an extra classpath inside your build.properties

jars.extra.classpath=

Tom

Am 07.12.11 14:04, schrieb J.-P. Pellet:
> I have the following setup:
>
> /mylibs/a.jar
> /mylibs/b.jar
>
> and an Eclipse project that should have a.jar on its classpath for
> building. Unfortunately — something that I cannot change — a.jar has a
> manifest with an entry like this:
>
> Class-Path: b.jar
>
> so Eclipse also automatically adds b.jar in the list of referenced
> libraries — except I don't want it.
>
> How can I prevent Eclipse to add b.jar from being added to the list of
> libraries?
>
> TIA,
> J.-P.
Re: How can I tell Eclipse to not include other jars on a jar dependency's classpath? [message #762041 is a reply to message #762037] Wed, 07 December 2011 08:17 Go to previous messageGo to next message
J.-P. Pellet is currently offline J.-P. Pellet
Messages: 71
Registered: July 2009
Member
Hi Tom,

Thanks for your answer. I think I'm missing something here… How can
setting the extra classpath remove b.jar from the list of referenced
libraries?

Cheers,
J.-P.

On 07.12.11 14:12, Tom Schindl wrote:
> You can set an extra classpath inside your build.properties
>
> jars.extra.classpath=
>
> Tom
Re: How can I tell Eclipse to not include other jars on a jar dependency's classpath? [message #762046 is a reply to message #762041] Wed, 07 December 2011 08:26 Go to previous messageGo to next message
Thomas Schindl is currently offline Thomas Schindl
Messages: 5257
Registered: July 2009
Senior Member
Am 07.12.11 14:17, schrieb J.-P. Pellet:
> Hi Tom,
>
> Thanks for your answer. I think I'm missing something here… How can
> setting the extra classpath remove b.jar from the list of referenced
> libraries?

Ah you are talking about a JDT project - then my message makes no sense.

Tom
Re: How can I tell Eclipse to not include other jars on a jar dependency's classpath? [message #762064 is a reply to message #762031] Wed, 07 December 2011 08:50 Go to previous messageGo to next message
Dani Megert is currently offline Dani Megert
Messages: 3801
Registered: July 2009
Senior Member
On 07.12.2011 14:04, J.-P. Pellet wrote:
> I have the following setup:
>
> /mylibs/a.jar
> /mylibs/b.jar
>
> and an Eclipse project that should have a.jar on its classpath for
> building. Unfortunately — something that I cannot change — a.jar has a
> manifest with an entry like this:
>
> Class-Path: b.jar
>
> so Eclipse also automatically adds b.jar in the list of referenced
> libraries — except I don't want it.
>
> How can I prevent Eclipse to add b.jar from being added to the list of
> libraries?
Create a User Library with 'a.jar' in it. We don't resolve referenced
libraries for those.

Dani
>
> TIA,
> J.-P.
Re: How can I tell Eclipse to not include other jars on a jar dependency's classpath? [message #762070 is a reply to message #762064] Wed, 07 December 2011 09:00 Go to previous message
J.-P. Pellet is currently offline J.-P. Pellet
Messages: 71
Registered: July 2009
Member
>> How can I prevent Eclipse to add b.jar from being added to the list of
>> libraries?
> Create a User Library with 'a.jar' in it. We don't resolve referenced
> libraries for those.

Thanks a lot!

Best,
J.-P.
Previous Topic:QuickFixProcessor performance (profiling)
Next Topic:Help with Java code formatter
Goto Forum:
  


Current Time: Wed Jul 30 17:35:19 EDT 2014

Powered by FUDForum. Page generated in 0.01823 seconds