possible addition of global switch to pkg
Matthew Seaman
matthew at FreeBSD.org
Sat Jun 6 18:15:04 UTC 2020
On 06/06/2020 17:31, Donald Wilde wrote:
> while doing another install of 12-STABLE, I thought of something
> simple that would be a helpful addition to the pkg installer. I was
> installing boost-all (from the port, in this case) and I was struck by
> the number of times the pkg dialog box popped up with JUST the
> checkbox for documentation.
>
> It would be really nice if there was a global switch that would
> automagically select for installing (or not installing) the pkg
> documentation. -d/-D are available, at least for the pkg install
> form... :D
This isnt a pkg(8) thing. pkg doesn't throw up any dialog boxes itself.
If you install using the standard pre-compiled packages, you'll just
get the docs installed, no questions asked, because that is the default
setting.
I guess what you're talking about is actually compiling your own
packages -- in which case, yes, you will see options dialog boxes quite
regularly. Given that, there is a simple global switch you can use.
Simply add one or other of the lines
OPTIONS_UNSET= docs
or
OPTIONS_SET= docs
according to taste to /etc/make.conf (or
/usr/local/etc/poudriere.d/make.conf if using pousdriere). In fact, if
there are any other options you want set or unset globally, those two
variables will each take a space separated list of option names.
See the commentary in ${PORTSDIR}/Mk/bsd.options.mk for the gory details
plus some other variations on options variables that should let you tune
things precisely to your liking.
The other thing looming on the horizon is sub-packages, which hasn't hit
the ports tree yet but there's a review at
https://reviews.freebsd.org/D16457
In essense this just divides the files created during compilation into
several different packages, each of which could be installed
more-or-less independently. (At the moment, each compilation of a port
generates exactly one package, although with things like flavors, any
one port can be recompiled several different ways to create the
different flavours)
So, alongside your package foo-1.2.3 containing the foo application,
there could be a foo-docs-1.2.3 with the documentation,
foo-examples-1.2.3 with examples, foo-devel-1.2.3 with header files and
a statically linked or profiled library, foo-debug-1.2.3 with separate
debug symbols, etc. etc.
Cheers,
Matthew
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 963 bytes
Desc: OpenPGP digital signature
URL: <http://lists.freebsd.org/pipermail/freebsd-pkg/attachments/20200606/8c93d9b3/attachment.sig>
More information about the freebsd-pkg
mailing list