Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 09 May 2006 14:21:26 +0200
From:      "[LoN]Kamikaze" <LoN_Kamikaze@gmx.de>
To:        Jeremy Chadwick <freebsd@jdc.parodius.com>,  Sideris Michael <msid@daemons.gr>, freebsd-ports@freebsd.org
Subject:   Re: ports structure and improvement suggestions
Message-ID:  <44608946.6000804@gmx.de>
In-Reply-To: <20060509111435.GA1228@roadrunner.aventurien.local>
References:  <20060508200926.GA6005@daemons.gr>	<20060509061026.GA14039@pentarou.parodius.com> <20060509111435.GA1228@roadrunner.aventurien.local>

index | next in thread | previous in thread | raw e-mail

Ulrich Spoerlein wrote:
> Jeremy Chadwick wrote:
>> # No IPv6, and no X11
>> IPV6 = no
>> X11  = no
>>
>> devel/gettext {
>>   EXAMPLES = no
>>   HTMLMAN  = no
>> }
>> www/apache20 {
>>   KQUEUE_SUPPORT = yes
>> }
>> www/suphp {
>>   CHECKPATH = no
>>   LOGFILE   = /var/log/suphp.log
>> }
>> net/cvsup {
>>   X11 = yes
>> }
>>
>> [snip]
> 
> You can already do this with make(1)-magic in /etc/make.conf. This is
> also guaranteed to work, whereas the pkgtools.conf approach is flawed.
> 
> Example /etc/make.conf (platform specific)
> 
> .if ${.CURDIR:M*/usr/ports*}
> CFLAGS+=       -Os
> WRKDIRPREFIX=   /vol/obj
> .include "/etc/ports.conf"
> .endif
> 
> And my /etc/ports.conf (platform independant, meaning I share it across
> several machines)
> 
> BATCH=          true
> PACKAGE_BUILDING=true
> WITH_OPENSSL_BASE=yes
> PAPERSIZE=      a4
> A4=             true
> WITH_GHOSTSCRIPT_AFPL=  yes
> 
> .if ${.CURDIR:M*/audio/amarok}
> WITH_XINE=      true
> #...
> .endif
> 
> .if ${.CURDIR:M*/audio/abcde}
> WITH_CDDA2WAV=  true
> #...
> .endif
> 
> .if ${.CURDIR:M*/databases/postgresql*}
> #WITH_OPTIMIZED_CFLAGS= true
> .endif
> 
> .if ${.CURDIR:M*/multimedia/*}
> WITH_THEORA=    true
> WITH_X264=      true
> WITH_OPTIMIZED_CFLAGS=true
> WITH_XVID=      true
> #...
> .endif
> 
> This allows for global options, category specific options and individual
> options. It is processed early enough and doesn't care if you invoke
> make install or portinstall. It will produce a correct INDEX, though
> ports might be listed twice, since we have slave ports. The syntax
> stinks, of course, and you still have to hunt for the Knobs yourself.

There is a tutorial in German, with a rather big example make.conf .
http://wiki.bsdforen.de/index.php/Make.conf_optimieren#.2Fetc.2Fmake.conf

I can translate the tutorial if there is interest. It also shows how to
manage repeating port configuration tasks using lists and loops.


home | help

Want to link to this message? Use this
URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?44608946.6000804>