[talk] script for extracting FreeBSD /etc/src.conf file
George Rosamond
george at ceetonetechnology.com
Fri Feb 2 13:34:00 EST 2018
A while back there was an freebsd-arm@ discussion about building images
with the crochet tool, and including a sample src.conf file.
The src.conf file provides parameters for building or updating a system
from source. It allows different parts of the kernel to be removed, or
added. The relevant application for crochet was in reducing the
footprint of a system for embedded use, but there are obvious security
benefits. It is/was also relevant for building GPL-less systems. But
there's more obvious applications, like, do you really need pf, ipfw and
ipf in your base system? Bluetooth on a server? freebsd-update(8) if
you're following stable?
However, there's no default /etc/src.conf file in FreeBSD, and
maintaining one is tricky. There are unnoticed changes during releases.
The best method is to extract it from the man page, IMHO.
This is a script which I've toyed with for a while, and I think it's
"usable" for others who want to create an appropriate /etc/src.conf file
on the system the script is run. It might need more cleanup, since it's
been sitting in my attic for a while.
I still maybe sort out the hierarchical aspects of the src.conf, ie, if
you set WITHOUT_WIRELESS it also enforces WITHOUT_WIRELESS_SUPPORT.
It assumes user land and the kernel are in sync, of course.
http://wiki.torbsd.org/doku.php?id=en:a_shell_script_to_convert_src.conf_5_contents_to_an_example_etc_src.conf_file
I'm curious to hear if others regularly use the /etc/src.conf file when
building from source. Any comments/input on it are welcome.
g
--
5822 F82D 665B 5C6A 915B FAD4 B014 1CEE 545A A6C6
More information about the talk
mailing list