diff mbox series

cross-canadian.bbclass: Do not override LIBCOVERRIDE with SDK libc override

Message ID 20190315062903.1431-1-raj.khem@gmail.com
State New
Headers show
Series cross-canadian.bbclass: Do not override LIBCOVERRIDE with SDK libc override | expand

Commit Message

Khem Raj March 15, 2019, 6:29 a.m. UTC
cross-canadian tools are supposed to generate code for target and if we
override the libc override then needed overrides do not get applied when
building gcc cross canadian e.g. for baremetal, which causes build
failures during compile

e.g. https://github.com/riscv/meta-riscv/issues/117

Not override libc override helps us fix this issue

Signed-off-by: Khem Raj <raj.khem@gmail.com>

---
 meta/classes/cross-canadian.bbclass | 1 -
 1 file changed, 1 deletion(-)

-- 
2.21.0

-- 
_______________________________________________
Openembedded-core mailing list
Openembedded-core@lists.openembedded.org
http://lists.openembedded.org/mailman/listinfo/openembedded-core

Comments

Alistair Francis March 15, 2019, 6:23 p.m. UTC | #1
On Thu, Mar 14, 2019 at 11:29 PM Khem Raj <raj.khem@gmail.com> wrote:
>

> cross-canadian tools are supposed to generate code for target and if we

> override the libc override then needed overrides do not get applied when

> building gcc cross canadian e.g. for baremetal, which causes build

> failures during compile

>

> e.g. https://github.com/riscv/meta-riscv/issues/117

>

> Not override libc override helps us fix this issue

>

> Signed-off-by: Khem Raj <raj.khem@gmail.com>


Reviewed-by: Alistair Francis <alistair.francis@wdc.com>

Tested-by: Alistair Francis <alistair.francis@wdc.com>


Alistair

> ---

>  meta/classes/cross-canadian.bbclass | 1 -

>  1 file changed, 1 deletion(-)

>

> diff --git a/meta/classes/cross-canadian.bbclass b/meta/classes/cross-canadian.bbclass

> index f5c9f61595..ee53faad79 100644

> --- a/meta/classes/cross-canadian.bbclass

> +++ b/meta/classes/cross-canadian.bbclass

> @@ -9,7 +9,6 @@

>  # or indirectly via dependency.  No need to be in 'world'.

>  EXCLUDE_FROM_WORLD = "1"

>  NATIVESDKLIBC ?= "libc-glibc"

> -LIBCOVERRIDE = ":${NATIVESDKLIBC}"

>  CLASSOVERRIDE = "class-cross-canadian"

>  STAGING_BINDIR_TOOLCHAIN = "${STAGING_DIR_NATIVE}${bindir_native}/${SDK_ARCH}${SDK_VENDOR}-${SDK_OS}:${STAGING_DIR_NATIVE}${bindir_native}/${TARGET_ARCH}${TARGET_VENDOR}-${TARGET_OS}"

>

> --

> 2.21.0

>

> --

> _______________________________________________

> 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
Richard Purdie March 18, 2019, 2:12 p.m. UTC | #2
On Thu, 2019-03-14 at 23:29 -0700, Khem Raj wrote:
> cross-canadian tools are supposed to generate code for target and if

> we

> override the libc override then needed overrides do not get applied

> when

> building gcc cross canadian e.g. for baremetal, which causes build

> failures during compile

> 

> e.g. https://github.com/riscv/meta-riscv/issues/117

> 

> Not override libc override helps us fix this issue

> 

> Signed-off-by: Khem Raj <raj.khem@gmail.com>

> ---

>  meta/classes/cross-canadian.bbclass | 1 -

>  1 file changed, 1 deletion(-)

> 

> diff --git a/meta/classes/cross-canadian.bbclass

> b/meta/classes/cross-canadian.bbclass

> index f5c9f61595..ee53faad79 100644

> --- a/meta/classes/cross-canadian.bbclass

> +++ b/meta/classes/cross-canadian.bbclass

> @@ -9,7 +9,6 @@

>  # or indirectly via dependency.  No need to be in 'world'.

>  EXCLUDE_FROM_WORLD = "1"

>  NATIVESDKLIBC ?= "libc-glibc"

> -LIBCOVERRIDE = ":${NATIVESDKLIBC}"

>  CLASSOVERRIDE = "class-cross-canadian"

>  STAGING_BINDIR_TOOLCHAIN =

> "${STAGING_DIR_NATIVE}${bindir_native}/${SDK_ARCH}${SDK_VENDOR}-

> ${SDK_OS}:${STAGING_DIR_NATIVE}${bindir_native}/${TARGET_ARCH}${TARGE

> T_VENDOR}-${TARGET_OS}"


Whilst I understand the problem, we need to be cautious here.

*-cross-canadian-* runs on nativesdk and for example often use glibc
even when the target uses musl. This change is partly reverting fixes
made to ensure that nativesdk worked as glibc (and glibc overrides were
applied correctly) even when the target system used musl.

I think this issue may need more investigation unfortunately...

Cheers,

Richard

-- 
_______________________________________________
Openembedded-core mailing list
Openembedded-core@lists.openembedded.org
http://lists.openembedded.org/mailman/listinfo/openembedded-core
diff mbox series

Patch

diff --git a/meta/classes/cross-canadian.bbclass b/meta/classes/cross-canadian.bbclass
index f5c9f61595..ee53faad79 100644
--- a/meta/classes/cross-canadian.bbclass
+++ b/meta/classes/cross-canadian.bbclass
@@ -9,7 +9,6 @@ 
 # or indirectly via dependency.  No need to be in 'world'.
 EXCLUDE_FROM_WORLD = "1"
 NATIVESDKLIBC ?= "libc-glibc"
-LIBCOVERRIDE = ":${NATIVESDKLIBC}"
 CLASSOVERRIDE = "class-cross-canadian"
 STAGING_BINDIR_TOOLCHAIN = "${STAGING_DIR_NATIVE}${bindir_native}/${SDK_ARCH}${SDK_VENDOR}-${SDK_OS}:${STAGING_DIR_NATIVE}${bindir_native}/${TARGET_ARCH}${TARGET_VENDOR}-${TARGET_OS}"