make KNOBS

Jeremy Chadwick koitsu at freebsd.org
Tue Feb 26 13:44:55 UTC 2008


On Tue, Feb 26, 2008 at 06:33:37AM -0600, Scot Hetzel wrote:
> On Tue, Feb 26, 2008 at 2:03 AM, Jeremy Chadwick <koitsu at freebsd.org> wrote:
> > Additionally, the WITH/WITHOUT variables seen in the Makefile are not
> > always what they seem.  For ports that use OPTIONS, you cannot define
> > these on the command-line (e.g. make WITHOUT_FRUIT=yes); you absolutely
> > MUST do 'make config' and then toggle them there.  (This is one piece of
> > the OPTIONS framework which I have always disliked, because some of us
> > use /etc/make.conf to define WITH/WITHOUT variables, and prefer to do
> > "cd /usr/ports/whatever && make clean && make && make install" and not
> > have something interactive pop up.  That's for another discussion
> > though...)
> >
> You should be able to do:
> 
> cd /usr/ports/whatever && make clean && make -DBATCH && make -DBATCH install
> 
> Check the port to see if it disables parts of its build/install
> process when BATCH is defined.

I thought using BATCH had some substantial risks associated with it?  I
wish I could remember where I read or heard that...

> Another way would be to define _OPTIONS_OK=yes in /etc/make.conf, but
> this is an internal variable to bsd.ports.mk.

What are the risks involved with using this?

> Also defining WITH/WITHOUT variables in /etc/make.conf and/or
> ${PREFIX}/etc/ports.conf (sysutils/portconf) should work with ports
> that use the OPTIONS framework.

In the case of the lesser, it doesn't.  In the case of the latter, I
don't use portconf, so I don't have an answer to that one.

-- 
| Jeremy Chadwick                                    jdc at parodius.com |
| Parodius Networking                           http://www.parodius.com/ |
| UNIX Systems Administrator                      Mountain View, CA, USA |
| Making life hard for others since 1977.                  PGP: 4BD6C0CB |



More information about the freebsd-stable mailing list