defining dependencies for ports

mh983 mh983 at yahoo.com
Mon Jul 17 16:27:09 UTC 2006



----- Original Message ----
From: Alex Zbyslaw <xfb52 at dial.pipex.com>
To: mike <mh983 at yahoo.com>
Cc: freebsd-questions at freebsd.org
Sent: Monday, July 17, 2006 11:19:15 AM
Subject: Re: defining dependencies for ports

mike wrote:

> Thanks for the responses.  This is /exactly/ why I'm using ports 
> instead of packages, because I want to have things compiled with my 
> options.  However, the reason for my original post was that I'm having 
> a hard time customizing this, for java/Eclipse specifically.  I try 
> "make config" but it doesn't show anything.  So how do I go about 
> cutting out or changing some of the dependencies that I don't want if 
> there are no OPTIONS defined?
> And I can't find where these dependencies are even defined in this 
> case.  I grep everything in /usr/ports/java/eclipse and don't see 
> references to most of the dependencies.  Where are they defined if not 
> in the BUILD_DEPENDS, etc. variables of the Makefile?
>
What options you get for any port do depend on what the maintainer chose 
to put in.  If there is some option that eclipse itself has, but the 
port does not, then contacting the maintainer is where I might start.

Looking thought the eclipse Makefile you see things like:

.if defined(WITH_MOTIF)

or

.if !defined(WITHOUT_MOZILLA)

which tell you what is going to be looked for when the port is 
compiled.  Is that what you meant by dependencies?

So if using plain make you say something like "make WITH_MOTIF=1" or 
"make WITHOUT_MOZILLA=1".

Using portupgrade, you can add these to the MAKE_ARGS for java/eclipse 
in pkgtools.conf and have them used automatically every time you recompile.

Or there is

BUILD_DEPENDS=  ant:${PORTSDIR}/devel/apache-ant \
                zip:${PORTSDIR}/archivers/zip

but usually they are not optional for a reason!

What, specifically, were you trying to do?

Not every port supports "make config" unfortunately.  I haven't done 
enough port hacking to know how easy it is to add this to any port, but 
can't believe it's that hard - of course, hard depends on your 
experience!  Comparing to a port which *does* support make config 
(mozilla, samba3, portupgrade) may help you do it for yourself; the 
Porters Handbook on the website may also have helpful info.

hth,

--Alex


Yes, that helps.  I did find the zip and ant dependencies.  When I had looked at the dependency tree on the web, there were a lot of others, such as glade which then requires python.  I didn't want glade or python, so I was kind of curious where this dependency was listed if not explicit in the Makefile.  I guess my question was more just in general than specifically for the Eclipse package.  From what you said, it sounds like it all just depends on how the port was written by the owner, if things are considered an option you can change or not.  Thanks for taking the time to actually go and look at the Makefile for this, that was above and beyond.

mike





More information about the freebsd-questions mailing list