toaster: build missing toaster.conf settings
PATCH 1/1 toaster: build missing toaster.conf settings
From: David Reyna <[email protected]>
The bitbake server changed such that the Toaster custom settings from 'toaster.conf' and 'toaster-bblayers.conf' that were set when the '--server-only' mode was started were lost when the subsequent build request happened, resulting in builds missing all custom changes.
This patch asserts those environment settings in both server calls.
[YOCTO #12194]
--- bitbake/lib/toaster/bldcontrol/localhostbecontroller.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-)
bitbake/lib/toaster/bldcontrol/localhostbecontroller.py +3 -2
@@ -381,9 +381,10 @@ class LocalhostBEController(BuildEnvironmentController): local_bitbake = os.path.join(os.path.dirname(os.getenv('BBBASEDIR')), 'bitbake') self._shellcmd(['bash -c \"(TOASTER_BRBE="%s" BBSERVER="0.0.0.0:%s" ' - '%s %s -u toasterui --token="" >>%s 2>&1;' + '%s %s -u toasterui --read %s --read %s --token="" >>%s 2>&1;' 'BITBAKE_UI="knotty" BBSERVER=0.0.0.0:%s %s -m)&\"' \ - % (brbe, self.be.bbport, local_bitbake, bbtargets, log, self.be.bbport, bitbake)], + % (brbe, self.be.bbport, local_bitbake, bbtargets, confpath, toasterlayers, log, + self.be.bbport, bitbake,)], builddir, nowait=True) logger.debug('localhostbecontroller: Build launched, exiting. '
Signature · 1 line
1.9.1
Hi David,
Quoted 24 lines · NZDT David Reyna
From: David Reyna <[email protected]>
The bitbake server changed such that the Toaster custom settings from 'toaster.conf' and 'toaster-bblayers.conf' that were set when the '--server-only' mode was started were lost when the subsequent build request happened, resulting in builds missing all custom changes.
This patch asserts those environment settings in both server calls.
[YOCTO #12194]
Signed-off-by David Reyna <[email protected]>--- bitbake/lib/toaster/bldcontrol/localhostbecontroller.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-)bitbake/lib/toaster/bldcontrol/localhostbecontroller.py +0
-0@@ -381,9 +381,10 @@ class LocalhostBEController(BuildEnvironmentController): local_bitbake = os.path.join(os.path.dirname(os.getenv('BBBASEDIR')), 'bitbake')
bitbake/lib/toaster/bldcontrol/localhostbecontroller.py class LocalhostBEController(BuildEnvironmentController): · line 390
Quoted 10 lines
bitbake/lib/toaster/bldcontrol/localhostbecontroller.py +3
-2self._shellcmd(['bash -c \"(TOASTER_BRBE="%s" BBSERVER="0.0.0.0:%s" ' - '%s %s -u toasterui --token="" >>%s 2>&1;' + '%s %s -u toasterui --read %s --read %s --token="" >>%s 2>&1;' 'BITBAKE_UI="knotty" BBSERVER=0.0.0.0:%s %s -m)&\"' \ - % (brbe, self.be.bbport, local_bitbake, bbtargets, log, self.be.bbport, bitbake)], + % (brbe, self.be.bbport, local_bitbake, bbtargets, confpath, toasterlayers, log, + self.be.bbport, bitbake,)], builddir, nowait=True) logger.debug('localhostbecontroller: Build launched, exiting. '
So after a pointer from Brian I looked at this and the change in behaviour is correct - bitbake will clear out any prefiles specified in a previous invocation even if that was the invocation that started the server. This behaviour wasn't well-defined and so it was working by accident beforehand. We didn't appreciate that it would break Toaster however, sorry about that.
We definitely need this fixed for 2.4 so I will send this to the bitbake list with my sign-off and hopefully that will accelerate getting the fix in.
Cheers,
Paul
Signature · 2 lines
Paul Eggleton Intel Open Source Technology Centre
Quoted 1 line
We definitely need this fixed for 2.4 so I will send this to the bitbake list with my sign-off and hopefully that will accelerate getting the fix in.
Thank you so much! I will watch for this and be available if there are any questions.
I hate making last minute requests, but I have tested the patch, the patch is simple, and I believe that there is no risk to YP-2.4 with this change.
- David
-----Original Message-----
From: Paul Eggleton [mailto:[email protected]]
Sent: Thursday, October 05, 2017 3:35 PM
To: Reyna, David
Cc: [email protected]
Subject: Re: [Toaster] [PATCH] toaster: build missing toaster.conf settings
Hi David,
Quoted 25 lines · NZDT David Reyna
From: David Reyna <[email protected]>
The bitbake server changed such that the Toaster custom settings from 'toaster.conf' and 'toaster-bblayers.conf' that were set when the '--server-only' mode was started were lost when the subsequent build request happened, resulting in builds missing all custom changes.
This patch asserts those environment settings in both server calls.
[YOCTO #12194]
Signed-off-by David Reyna <[email protected]>--- bitbake/lib/toaster/bldcontrol/localhostbecontroller.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-)bitbake/lib/toaster/bldcontrol/localhostbecontroller.py +0
-0@@ -381,9 +381,10 @@ class LocalhostBEController(BuildEnvironmentController): local_bitbake = os.path.join(os.path.dirname(os.getenv('BBBASEDIR')), 'bitbake')
bitbake/lib/toaster/bldcontrol/localhostbecontroller.py class LocalhostBEController(BuildEnvironmentController): · line 390
Quoted 10 lines
bitbake/lib/toaster/bldcontrol/localhostbecontroller.py +3
-2self._shellcmd(['bash -c \"(TOASTER_BRBE="%s" BBSERVER="0.0.0.0:%s" ' - '%s %s -u toasterui --token="" >>%s 2>&1;' + '%s %s -u toasterui --read %s --read %s --token="" >>%s 2>&1;' 'BITBAKE_UI="knotty" BBSERVER=0.0.0.0:%s %s -m)&\"' \ - % (brbe, self.be.bbport, local_bitbake, bbtargets, log, self.be.bbport, bitbake)], + % (brbe, self.be.bbport, local_bitbake, bbtargets, confpath, toasterlayers, log, + self.be.bbport, bitbake,)], builddir, nowait=True) logger.debug('localhostbecontroller: Build launched, exiting. '
So after a pointer from Brian I looked at this and the change in behaviour is correct - bitbake will clear out any prefiles specified in a previous invocation even if that was the invocation that started the server. This behaviour wasn't well-defined and so it was working by accident beforehand. We didn't appreciate that it would break Toaster however, sorry about that.
We definitely need this fixed for 2.4 so I will send this to the bitbake list with my sign-off and hopefully that will accelerate getting the fix in.
Cheers,
Paul
Signature · 2 lines
Paul Eggleton Intel Open Source Technology Centre