From 0ba9a9fffee966ec912eec5fd52c468338560e6a Mon Sep 17 00:00:00 2001 From: Richard Purdie Date: Sun, 28 Nov 2010 17:39:09 +0000 Subject: bitbake: Overhaul environment handling Currently, anything whitelisted in the environment makes it into the worker processes. This is undesireable and the worker environment should be as clean as possible. This patch adapts bitbake sosme variables are loaded into bitbake's datastore but not exported by default. Any variable can be exported by setting its export flag. Currently, this code only finalises the environment in he worker as doing so in the server means variables are unavailable in the worker. If we switch back to fork() calls instead of exec() this code will need revisting. Signed-off-by: Richard Purdie --- bitbake/bin/bitbake-runtask | 3 +++ 1 file changed, 3 insertions(+) (limited to 'bitbake/bin') diff --git a/bitbake/bin/bitbake-runtask b/bitbake/bin/bitbake-runtask index 88101a5c0f..9079f5725b 100755 --- a/bitbake/bin/bitbake-runtask +++ b/bitbake/bin/bitbake-runtask @@ -100,6 +100,9 @@ the_data = cooker.bb_cache.loadDataFull(fn, cooker.get_file_appends(fn), cooker. cooker.bb_cache.setData(fn, buildfile, the_data) cooker.bb_cache.handle_data(fn, cooker.status) +exportlist = bb.utils.preserved_envvars_export_list() +bb.utils.filter_environment(exportlist) + if taskname.endswith("_setscene"): the_data.setVarFlag(taskname, "quieterrors", "1") -- cgit v1.2.3-54-g00ecf