Does this patch (and the follow-on series) make sense for inclusion in dunfell?

Steve

On Sun, May 24, 2020 at 9:46 PM Michael Ho <michael...@bmw.de> wrote:
>
> From: Michael Ho <michael...@bmw.de>
>
> Apply ${PN} to OVERRIDES when determining the base package spec variables.
> Without this, there is a mismatch in behaviour where overrides for the base
> package have no effect while overrides for subpackages do. The subpackages
> should not be affected by this override as they apply their own package
> overrides and will by default fetch the base variables and apply them in
> the spec file.
>
> This makes the behaviour for package overrides match the implementation
> in package_deb.bbclass and package_ipk.bbclass.
>
> Signed-off-by: Michael Ho <michael...@bmw.de>
> ---
>  meta/classes/package_rpm.bbclass | 22 ++++++++++++----------
>  1 file changed, 12 insertions(+), 10 deletions(-)
>
> diff --git a/meta/classes/package_rpm.bbclass 
> b/meta/classes/package_rpm.bbclass
> index 9a4be2e..519c22b 100644
> --- a/meta/classes/package_rpm.bbclass
> +++ b/meta/classes/package_rpm.bbclass
> @@ -286,16 +286,18 @@ python write_specfile () {
>
>      # Construct the SPEC file...
>      srcname    = d.getVar('PN')
> -    srcsummary = (d.getVar('SUMMARY') or d.getVar('DESCRIPTION') or ".")
> -    srcversion = d.getVar('PKGV').replace('-', '+')
> -    srcrelease = d.getVar('PKGR')
> -    srcepoch   = (d.getVar('PKGE') or "")
> -    srclicense = d.getVar('LICENSE')
> -    srcsection = d.getVar('SECTION')
> -    srcmaintainer  = d.getVar('MAINTAINER')
> -    srchomepage    = d.getVar('HOMEPAGE')
> -    srcdescription = d.getVar('DESCRIPTION') or "."
> -    srccustomtagschunk = get_package_additional_metadata("rpm", d)
> +    localdata = bb.data.createCopy(d)
> +    localdata.setVar('OVERRIDES', d.getVar("OVERRIDES", False) + ":" + 
> srcname)
> +    srcsummary = (localdata.getVar('SUMMARY') or 
> localdata.getVar('DESCRIPTION') or ".")
> +    srcversion = localdata.getVar('PKGV').replace('-', '+')
> +    srcrelease = localdata.getVar('PKGR')
> +    srcepoch   = (localdata.getVar('PKGE') or "")
> +    srclicense = localdata.getVar('LICENSE')
> +    srcsection = localdata.getVar('SECTION')
> +    srcmaintainer  = localdata.getVar('MAINTAINER')
> +    srchomepage    = localdata.getVar('HOMEPAGE')
> +    srcdescription = localdata.getVar('DESCRIPTION') or "."
> +    srccustomtagschunk = get_package_additional_metadata("rpm", localdata)
>
>      srcdepends     = d.getVar('DEPENDS')
>      srcrdepends    = []
> --
> 2.7.4
>
> 
-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.

View/Reply Online (#138725): 
https://lists.openembedded.org/g/openembedded-core/message/138725
Mute This Topic: https://lists.openembedded.org/mt/74452506/21656
Group Owner: openembedded-core+ow...@lists.openembedded.org
Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub  
[arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-

Reply via email to