Re: [OE-core] [PATCH 2/2] bitbake.conf: Simplify TARGET_SYS/SDK_SYS
On Mon, 2019-12-30 at 14:10 -0800, Khem Raj wrote: > On Mon, Dec 30, 2019 at 12:48 AM Richard Purdie > wrote: > > As pointed out by Masahiro Yamada , ('' or > > 'custom') > > equates to "custom" and this code seems unecesaarily complicated > > and unused. > > > > It was likely intended to supress the value if XXX_OS was set to '' > > but the > > code doesn't actually do that. Simplify it as we shouldn't have > > this indirection > > if we don't need it, its horrible. > > > > introduced here in oe classic > https://git.openembedded.org/openembedded/commit/?id=e485a5d542a24109c8ab97e58916359efc0cd044 > > and fixed here > https://git.openembedded.org/openembedded/commit/?id=ff02b94de71 > > downstreamed into poky > https://git.openembedded.org/openembedded-core/commit/?id=5ad6d9a94a0 > > I think oe-core missed the second commit. perhaps it seems that it > was created out of poky lineage rather than oe classic. > > maybe porting the second commit above would be better option here. Maybe, except that nobody has complained in 8 years. The expression is horrible so I'd prefer to drop it if we don't need it. If needed someone can override the variable anyway... Cheers, Richard -- ___ Openembedded-core mailing list Openembedded-core@lists.openembedded.org http://lists.openembedded.org/mailman/listinfo/openembedded-core
Re: [OE-core] [PATCH 2/2] bitbake.conf: Simplify TARGET_SYS/SDK_SYS
On Mon, Dec 30, 2019 at 12:48 AM Richard Purdie wrote: > > As pointed out by Masahiro Yamada , ('' or 'custom') > equates to "custom" and this code seems unecesaarily complicated and unused. > > It was likely intended to supress the value if XXX_OS was set to '' but the > code doesn't actually do that. Simplify it as we shouldn't have this > indirection > if we don't need it, its horrible. > introduced here in oe classic https://git.openembedded.org/openembedded/commit/?id=e485a5d542a24109c8ab97e58916359efc0cd044 and fixed here https://git.openembedded.org/openembedded/commit/?id=ff02b94de71 downstreamed into poky https://git.openembedded.org/openembedded-core/commit/?id=5ad6d9a94a0 I think oe-core missed the second commit. perhaps it seems that it was created out of poky lineage rather than oe classic. maybe porting the second commit above would be better option here. > Signed-off-by: Richard Purdie > --- > meta/conf/bitbake.conf | 4 ++-- > 1 file changed, 2 insertions(+), 2 deletions(-) > > diff --git a/meta/conf/bitbake.conf b/meta/conf/bitbake.conf > index 394484b2b73..62b5466b717 100644 > --- a/meta/conf/bitbake.conf > +++ b/meta/conf/bitbake.conf > @@ -129,7 +129,7 @@ SDKUSE_NLS ??= "yes" > TARGET_ARCH = "${TUNE_ARCH}" > TARGET_OS = "linux${LIBCEXTENSION}${ABIEXTENSION}" > TARGET_VENDOR = "-oe" > -TARGET_SYS = "${TARGET_ARCH}${TARGET_VENDOR}${@['-' + d.getVar('TARGET_OS'), > ''][d.getVar('TARGET_OS') == ('' or 'custom')]}" > +TARGET_SYS = "${TARGET_ARCH}${TARGET_VENDOR}-${TARGET_OS}" > TARGET_PREFIX = "${TARGET_SYS}-" > TARGET_CC_ARCH = "${TUNE_CCARGS}" > TARGET_LD_ARCH = "${TUNE_LDARGS}" > @@ -138,7 +138,7 @@ TARGET_AS_ARCH = "${TUNE_ASARGS}" > SDKMACHINE ??= "x86_64" > SDK_OS = "${BUILD_OS}" > SDK_VENDOR = "-oesdk" > -SDK_SYS = "${SDK_ARCH}${SDK_VENDOR}${@['-' + d.getVar('SDK_OS'), > ''][d.getVar('SDK_OS') == ('' or 'custom')]}" > +SDK_SYS = "${SDK_ARCH}${SDK_VENDOR}-${SDK_OS}" > SDK_PREFIX = "${SDK_SYS}-" > SDK_CC_ARCH = "${BUILD_CC_ARCH}" > SDKPKGSUFFIX = "nativesdk" > -- > 2.20.1 > > -- > ___ > Openembedded-core mailing list > Openembedded-core@lists.openembedded.org > http://lists.openembedded.org/mailman/listinfo/openembedded-core -- ___ Openembedded-core mailing list Openembedded-core@lists.openembedded.org http://lists.openembedded.org/mailman/listinfo/openembedded-core
[OE-core] [PATCH 2/2] bitbake.conf: Simplify TARGET_SYS/SDK_SYS
As pointed out by Masahiro Yamada , ('' or 'custom') equates to "custom" and this code seems unecesaarily complicated and unused. It was likely intended to supress the value if XXX_OS was set to '' but the code doesn't actually do that. Simplify it as we shouldn't have this indirection if we don't need it, its horrible. Signed-off-by: Richard Purdie --- meta/conf/bitbake.conf | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/meta/conf/bitbake.conf b/meta/conf/bitbake.conf index 394484b2b73..62b5466b717 100644 --- a/meta/conf/bitbake.conf +++ b/meta/conf/bitbake.conf @@ -129,7 +129,7 @@ SDKUSE_NLS ??= "yes" TARGET_ARCH = "${TUNE_ARCH}" TARGET_OS = "linux${LIBCEXTENSION}${ABIEXTENSION}" TARGET_VENDOR = "-oe" -TARGET_SYS = "${TARGET_ARCH}${TARGET_VENDOR}${@['-' + d.getVar('TARGET_OS'), ''][d.getVar('TARGET_OS') == ('' or 'custom')]}" +TARGET_SYS = "${TARGET_ARCH}${TARGET_VENDOR}-${TARGET_OS}" TARGET_PREFIX = "${TARGET_SYS}-" TARGET_CC_ARCH = "${TUNE_CCARGS}" TARGET_LD_ARCH = "${TUNE_LDARGS}" @@ -138,7 +138,7 @@ TARGET_AS_ARCH = "${TUNE_ASARGS}" SDKMACHINE ??= "x86_64" SDK_OS = "${BUILD_OS}" SDK_VENDOR = "-oesdk" -SDK_SYS = "${SDK_ARCH}${SDK_VENDOR}${@['-' + d.getVar('SDK_OS'), ''][d.getVar('SDK_OS') == ('' or 'custom')]}" +SDK_SYS = "${SDK_ARCH}${SDK_VENDOR}-${SDK_OS}" SDK_PREFIX = "${SDK_SYS}-" SDK_CC_ARCH = "${BUILD_CC_ARCH}" SDKPKGSUFFIX = "nativesdk" -- 2.20.1 -- ___ Openembedded-core mailing list Openembedded-core@lists.openembedded.org http://lists.openembedded.org/mailman/listinfo/openembedded-core