batching port builds
RW
list-freebsd-2004 at morbius.sent.com
Sat Jul 1 03:06:29 UTC 2006
On Friday 30 June 2006 17:31, David J Brooks wrote:
> On Friday 30 June 2006 11:10, Michael P. Soulier wrote:
> > Apologies if this is in a FAQ, I didn't see it.
> >
> > How does one tell the ports system to not query interactively for input,
> > and just take default build options, or a predefined set of options?
> > Running a portupgrade -a and finding the night wasted while the box sat
> > waiting for input is no fun at all.
>
> If you do 'make -DBATCH' instead of 'make' - you will use the preset
> defaults for each port with options. Or you can do
> 'make config-recursive' - which will offer you all the option screens for
> the port in whose directory you're currently in and all its dependencies.
>
> See 'man ports' for more information.
>
> To use those with 'portupgrade -a' will probably take some custom
> scripting.
>
> David
This is what I use:
-----------------------------------------------------------
#!/bin/sh
plist=`pkg_version -ovl'<' |awk '{ print $1 }'`
for porg in $plist ; do
cd /usr/ports/${porg} && make config-recursive
done
-----------------------------------------------------------
not pretty, but it works for me.
[Note: I use pkg_version, because neither pkg_version nor portmanager are
bothered by package database inconsistencies. portupgrade and portversion
both require full consistency so you may as well take advantage of
portversion's speed.]
More information about the freebsd-questions
mailing list