changing configure options when using a port
Matthew Seaman
m.seaman at infracaninophile.co.uk
Tue Jan 6 04:52:29 PST 2004
On Tue, Jan 06, 2004 at 10:33:49PM +1100, August Simonelli wrote:
> I'm slowly getting used to FreeBSD from a Linux background so forgive
> the ignorant questions.
>
> I'm curious what the best way to add configure options are when
> installing from a port. For example, i'd like to add --enable-rewrite
> to apache2. Can I just put it in the Makefile in /usr/ports/www/apache2
> ? Is this generally the best way to do this?
The apache2 port Makefile already comes with any number of hooks for
enabling or disabling various configuration options -- probably too
many in fact.
In your case, to enable mod_rewrite you don't need to do anything, as
it's already a standard part of the apache2 port, and enabled by
default in the sample httpd-std.conf file. To get a list of what
modules are available and what would be included when you build the
port, use:
# cd /usr/ports/www/apache2
# make show-modules
However, for the sake of completelness, you can compile the port to
include extra modules by:
# make WITH_EXTRA_MODULES=rewrite
or to statically link mod_rewrite into the apache binary:
# make WITH_STATIC_MODULES=rewrite
To apply these options without having to remember to type them in on
the command line all the time, you can create a 'Makefile.inc' in the
port directory which just contains the 'WITH_FOO=bar' variable
assignments, or you can use portupgrade(1) and record these
customizations in it's pkgtools.conf configuration file.
Cheers,
Matthew
--
Dr Matthew J Seaman MA, D.Phil. 26 The Paddocks
Savill Way
PGP: http://www.infracaninophile.co.uk/pgpkey Marlow
Tel: +44 1628 476614 Bucks., SL7 1TH UK
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 187 bytes
Desc: not available
Url : http://lists.freebsd.org/pipermail/freebsd-questions/attachments/20040106/6e133a98/attachment.bin
More information about the freebsd-questions
mailing list