Return-Path: Received: from mail.kmu-office.ch (mail.kmu-office.ch [178.209.48.109]) by mail.openembedded.org (Postfix) with ESMTP id 3EDBB782B4 for ; Thu, 17 Aug 2017 17:36:39 +0000 (UTC) Received: from webmail.kmu-office.ch (unknown [178.209.48.103]) by mail.kmu-office.ch (Postfix) with ESMTPSA id 60E145C05C3; Thu, 17 Aug 2017 19:33:33 +0200 (CEST) MIME-Version: 1.0 Date: Thu, 17 Aug 2017 10:34:07 -0700 From: Stefan Agner To: openembedded-core@lists.openembedded.org, akuster808@gmail.com In-Reply-To: <1504000440-16842-1-git-send-email-stefan@agner.ch> References: <1504000440-16842-1-git-send-email-stefan@agner.ch> Message-ID: <8662fc65d498ee9e62c0d0d8e8fbeff8@agner.ch> X-Sender: stefan@agner.ch User-Agent: Roundcube Webmail/1.2.5 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=agner.ch; s=dkim; t=1502991213; bh=ziSQ5rRfPRTnVUjVv6fy2JKMYstEzJEeNiH6aBcMXKE=; h=MIME-Version:Content-Type:Content-Transfer-Encoding:Date:From:To:Cc:Subject:In-Reply-To:References:Message-ID; b=TXtqLAWzVFJ1jv+mOj+UoF7R/RuWjpu6wizieZBT4tAfs7PRyL00oRwo/xBy8GmHIbH4xglPtTYPM0DErIzJLkRakc5abJyMmsMFI7zu4RJqTE31FkoR3b5OsSXWi1qFZ9dBWImC/hoGTdSpJiNJ68HHV3MgIxvCdpkGqSM4Yko= Cc: Stefan Agner Subject: Re: [PATCH v2] image.bbclass: delete DATE variable too X-BeenThere: openembedded-core@lists.openembedded.org X-Mailman-Version: 2.1.12 Precedence: list List-Id: Patches and discussions about the oe-core layer List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 17 Aug 2017 17:36:40 -0000 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit On 2017-08-29 02:54, Stefan Agner wrote: > From: Stefan Agner > > When creating a custom image which uses the DATE variable the basehash > seems to change every day and lead to errors such as: > ERROR: console-tdx-image-2.7.6-r0 do_image_customimg: Error executing > a python function in exec_python_func() autogenerated: > > The stack trace of python calls that resulted in this exception/failure was: > File: 'exec_python_func() autogenerated', lineno: 2, function: > 0001: > *** 0002:set_image_size(d) > ... > > Add DATE to the variables which should not get expanded early and to the > vardepsexclude list for the image task. Armin, this has been applied to master in between. Is there a chance to get that also into pyro and morty? -- Stefan > > Signed-off-by: Stefan Agner > --- > I am not that deep in OE usually and I am not sure if I miss something > completely here... It seems to solve the issue for us though. Does that > change sounds reasonable? Could it be done in the custom image class file? > > meta/classes/image.bbclass | 3 ++- > 1 file changed, 2 insertions(+), 1 deletion(-) > > diff --git a/meta/classes/image.bbclass b/meta/classes/image.bbclass > index 2c1dc81..7949b46 100644 > --- a/meta/classes/image.bbclass > +++ b/meta/classes/image.bbclass > @@ -437,6 +437,7 @@ python () { > # date/time values. It will get expanded at execution time. > # Similarly TMPDIR since otherwise we see QA stamp comparision problems > localdata.delVar('DATETIME') > + localdata.delVar('DATE') > localdata.delVar('TMPDIR') > > image_cmd = localdata.getVar("IMAGE_CMD") > @@ -501,7 +502,7 @@ python () { > d.prependVarFlag(task, 'postfuncs', ' create_symlinks') > d.appendVarFlag(task, 'subimages', ' ' + ' '.join(subimages)) > d.appendVarFlag(task, 'vardeps', ' ' + ' '.join(vardeps)) > - d.appendVarFlag(task, 'vardepsexclude', 'DATETIME') > + d.appendVarFlag(task, 'vardepsexclude', 'DATETIME DATE') > > bb.debug(2, "Adding task %s before %s, after %s" % (task, > 'do_image_complete', after)) > bb.build.addtask(task, 'do_image_complete', after, d)