Page MenuHomeFreeBSD

Allow additional "options" files to be specified in kernel config
ClosedPublic

Authored by stevek on Apr 12 2023, 9:07 PM.
Tags
None
Referenced Files
Unknown Object (File)
Fri, Nov 29, 11:54 AM
Unknown Object (File)
Tue, Nov 12, 11:13 PM
Unknown Object (File)
Oct 30 2024, 3:02 PM
Unknown Object (File)
Oct 3 2024, 10:14 PM
Unknown Object (File)
Oct 2 2024, 4:26 AM
Unknown Object (File)
Sep 29 2024, 10:01 PM
Unknown Object (File)
Sep 27 2024, 2:17 PM
Unknown Object (File)
Sep 19 2024, 1:56 AM
Subscribers

Details

Summary

The "includeoptions" directive can be used to specify an additional
options file to be used.

This is useful in conjunction with the "files" directive for build
environments to be able to add custom files and options.

Obtained from: Juniper Networks, Inc.

Diff Detail

Repository
rG FreeBSD src repository
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

stevek edited the summary of this revision. (Show Details)

Generally, it's fine, but I have a question...

usr.sbin/config/mkoptions.cc
372

this is unusual... why is it needed?

usr.sbin/config/mkoptions.cc
372

I missed that from when I was debugging some issues. Although it might be good to add a "verbose" flag and put prints such as this under a if (verbose) type of conditional.

I know it was useful when I was adding things for Juniper build where we have Juniper-specific changes under a top-level juniper/ directory and the "includeoptions" entry looks like this:
includeoptions "../../../juniper/sys/conf/options"

If one sets an includeoptions and the path is wrongly specified, it's useful to be able to have a message indicating what was trying to be read and the cwd that is the root of a relative path.

What do you think about adding a verbose flag and putting this under such a conditional (and possibly adding additional prints in other places under said conditional)?

usr.sbin/config/mkoptions.cc
372

A verbose flag would be fine...

Added -v flag for verbose mode. Added man page details for the flag.

This revision was not accepted when it landed; it landed in state Needs Review.Sep 18 2024, 5:03 PM
This revision was automatically updated to reflect the committed changes.