diff options
author | Richard Purdie <richard.purdie@linuxfoundation.org> | 2025-10-06 14:21:12 +0100 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2025-10-07 22:31:08 +0100 |
commit | 740db6078b51f101442dc3dc36f1863b1062cc00 (patch) | |
tree | f140bd9eac345048419d152f4bfc94242554e93b | |
parent | 3b81a5ba06f96b09dc2a06f83491aef7174d5d63 (diff) | |
download | poky-740db6078b51f101442dc3dc36f1863b1062cc00.tar.gz |
bitbake.conf,lib/configfragments: Use a new dedicated toolcfg.conf file
Rather than using auto.conf which already has established use in CI, or
local.conf which users expect to own/control, start writing "tooling"
controlled settings to a toolcfg.conf.
This frees CI to handle auto.conf as it wants, but avoids the tooling
breaking users local.conf files.
(From OE-Core rev: b5a50c14d74444e02bfddbbd640ab230a232d00c)
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
-rw-r--r-- | meta/conf/bitbake.conf | 1 | ||||
-rw-r--r-- | meta/lib/bbconfigbuild/configfragments.py | 4 |
2 files changed, 3 insertions, 2 deletions
diff --git a/meta/conf/bitbake.conf b/meta/conf/bitbake.conf index eebefc4840..8d1ea5491d 100644 --- a/meta/conf/bitbake.conf +++ b/meta/conf/bitbake.conf | |||
@@ -813,6 +813,7 @@ FILESOVERRIDES = "${TRANSLATED_TARGET_ARCH}:${MACHINEOVERRIDES}:${DISTROOVERRIDE | |||
813 | require conf/abi_version.conf | 813 | require conf/abi_version.conf |
814 | include conf/site.conf | 814 | include conf/site.conf |
815 | include conf/auto.conf | 815 | include conf/auto.conf |
816 | include conf/toolcfg.conf | ||
816 | include conf/local.conf | 817 | include conf/local.conf |
817 | 818 | ||
818 | OE_FRAGMENTS_PREFIX ?= "conf/fragments" | 819 | OE_FRAGMENTS_PREFIX ?= "conf/fragments" |
diff --git a/meta/lib/bbconfigbuild/configfragments.py b/meta/lib/bbconfigbuild/configfragments.py index 34c6a3b4bc..21baedc9a4 100644 --- a/meta/lib/bbconfigbuild/configfragments.py +++ b/meta/lib/bbconfigbuild/configfragments.py | |||
@@ -115,7 +115,7 @@ class ConfigFragmentsPlugin(LayerPlugin): | |||
115 | def create_conf(self, confpath): | 115 | def create_conf(self, confpath): |
116 | if not os.path.exists(confpath): | 116 | if not os.path.exists(confpath): |
117 | with open(confpath, 'w') as f: | 117 | with open(confpath, 'w') as f: |
118 | f.write('') | 118 | f.write('# Automated config file controlled by tools\n') |
119 | with open(confpath, 'r') as f: | 119 | with open(confpath, 'r') as f: |
120 | lines = f.read() | 120 | lines = f.read() |
121 | if "OE_FRAGMENTS += " not in lines: | 121 | if "OE_FRAGMENTS += " not in lines: |
@@ -184,7 +184,7 @@ class ConfigFragmentsPlugin(LayerPlugin): | |||
184 | print("All fragments removed from {}.".format(args.confpath)) | 184 | print("All fragments removed from {}.".format(args.confpath)) |
185 | 185 | ||
186 | def register_commands(self, sp): | 186 | def register_commands(self, sp): |
187 | default_confpath = os.path.join(os.environ["BBPATH"], "conf/auto.conf") | 187 | default_confpath = os.path.join(os.environ["BBPATH"], "conf/toolcfg.conf") |
188 | 188 | ||
189 | parser_list_fragments = self.add_command(sp, 'list-fragments', self.do_list_fragments, parserecipes=False) | 189 | parser_list_fragments = self.add_command(sp, 'list-fragments', self.do_list_fragments, parserecipes=False) |
190 | parser_list_fragments.add_argument("--confpath", default=default_confpath, help='Configuration file which contains a list of enabled fragments (default is {}).'.format(default_confpath)) | 190 | parser_list_fragments.add_argument("--confpath", default=default_confpath, help='Configuration file which contains a list of enabled fragments (default is {}).'.format(default_confpath)) |