what is the expected STAGING_INCDIR for cross packages?
Hello,
what is the expected STAGING_INCDIR for -cross packages?
Our STAGING_INCDIR for -cross packages contains two concatenated absolute paths, one based of CROSS_DIR, one based of STAGING_DIR.
Both are absolute, based against TMPDIR.
Is that correct?
i.e.
CROSS_DIR = ${TMPDIR}/cross/$BASE_PACKAGE_ARCH
prefix = ${CROSS_DIR}exec_prefix = ${prefix}
includedir = ${exec_prefix}/include
STAGING_DIR = ${TMPDIR}/staging BASEPKG_HOST_SYS=${HOST_ARCH}${HOST_VENDOR}-${HOST_OS} STAGING_DIR_HOST=${STAGIG_DIR}/$BASEPKG_HOST_SYS}
which are then concatenated for -cross packages as:
STAGING_INCDIR = "${STAGING_DIR_HOST}${includedir}"
Regards,
Signature · 1 line
Leon
Quoted 9 lines · Leon Woestenberg
what is the expected
STAGING_INCDIRfor -cross packages?Our
STAGING_INCDIRfor -cross packages contains two concatenated absolute paths, one based ofCROSS_DIR, one based ofSTAGING_DIR.Both are absolute, based against TMPDIR.
Is that correct?
Cross recipes are tricky. Half the time variables refer to the "host" and half the time they refer to the "target". This sounds like a case where the two have combined in a rather unfortunate way.
Where is this used and what kind of problem is occurring?
Quoted 4 lines
CROSS_DIR= ${TMPDIR}/cross/$BASE_PACKAGE_ARCH
prefix = ${CROSS_DIR}exec_prefix= ${prefix}
includedir = ${exec_prefix}/include
These all look correct. Cross packages are installed into "/" under ${prefix} which puts them in the correctly place
Quoted 7 lines
STAGING_DIR= ${TMPDIR}/staging BASEPKG_HOST_SYS=${HOST_ARCH}${HOST_VENDOR}-${HOST_OS} STAGING_DIR_HOST=${STAGIG_DIR}/$BASEPKG_HOST_SYS}which are then concatenated for -cross packages as:
STAGING_INCDIR= "${STAGING_DIR_HOST}${includedir}"
So I'd guess that cross.bbclass should be setting STAGING_DIR_HOST = "/" like native.bbclass does and then ${includedir} will map to the correct place.
I have to wonder what other side effects that would have of course (although there aren't that may -cross recipes to break comparatively speaking).
Cheers,
Richard
Hello Richard,
Quoted 5 lines · Richard Purdie
Quoted 1 line · Leon Woestenberg
what is the expected
STAGING_INCDIRfor -cross packages?Where is this used and what kind of problem is occurring?
It's in binutils-cross.
I'm adding a new architecture (nios2) which has additional staging steps in which it brings out a few binutils build-host specifics, in order for the following "elf2flt" tool to build.
Up-to-current binutils-cross did not stage anything, so we never saw this there.
(I'm aware this should fold into install with your packaged-staging cleanup, but I don't dare to move the binutils to the new approach just yet).
Regards,
Signature · 1 line
Leon
Quoted 14 lines · Leon Woestenberg
Hello Richard,
Quoted 5 lines · Richard Purdie
Quoted 1 line · Leon Woestenberg
what is the expected
STAGING_INCDIRfor -cross packages?Where is this used and what kind of problem is occurring?
It's in binutils-cross.
I'm adding a new architecture (nios2) which has additional staging steps in which it brings out a few binutils build-host specifics, in order for the following "elf2flt" tool to build.
Quoted 5 lines
Up-to-current binutils-cross did not stage anything, so we never saw this there.
(I'm aware this should fold into install with your packaged-staging cleanup, but I don't dare to move the binutils to the new approach just yet).
Take a look at what cross.bbclass looks like in Poky. There are things like ${target_includedir} defined there for exactly this kind of problem.
Cheers,
Richard
Hello,
Quoted 9 lines · Richard Purdie
Quoted 3 lines · Leon Woestenberg
Quoted 2 lines · Richard Purdie
Quoted 1 line · Leon Woestenberg
what is the expected
STAGING_INCDIRfor -cross packages?Take a look at what cross.bbclass looks like in Poky. There are things like ${target_includedir} defined there for exactly this kind of problem.
This seems the right approach.
Emptying STAGING_DIR_HOST opened another can of worms (/shlibs related).
Groeten,
Signature · 1 line
Leon
Quoted 3 lines · Leon Woestenberg
I'm adding a new architecture (nios2) which has additional staging steps in which it brings out a few binutils build-host specifics, in order for the following "elf2flt" tool to build.
elf2flt brings back nasty uclinux memories here ;)
regards,
Koen
Hello Koen, all,
Quoted 8 lines · Koen Kooi
Quoted 3 lines · Leon Woestenberg
I'm adding a new architecture (nios2) which has additional staging steps in which it brings out a few binutils build-host specifics, in order for the following "elf2flt" tool to build.
elf2flt brings back nasty uclinux memories here ;)
Yes, happily, the nios2 now has a mmu-full variant as well.
Not that their toolchains don't suck, I have the feeling I'm opening another can of worms.
Regards,
Signature · 1 line
Leon