* gcc 4.9.1 and stdint.h
@ 2014-11-02 20:05 Holger Hans Peter Freyther
2014-11-02 22:03 ` Richard Purdie
0 siblings, 1 reply; 9+ messages in thread
From: Holger Hans Peter Freyther @ 2014-11-02 20:05 UTC (permalink / raw)
To: poky
Hi,
I have a small piece of initial bootloader and it fails to compile
using master (f19b4e995ea47f9243f152b39337330307453c9f). The code
does include "stdint.h" which ends up with a failure like this:
tmp/sysroots/i686-linux/usr/lib/arm-poky-linux-gnueabi/gcc/arm-poky-linux-gnueabi/4.9.1/include/stdint.h:9:26: fatal error: stdint.h: No such file or directory
| # include_next <stdint.h>
| ^
| compilation terminated.
So somehow gcc doesn't know how to find the glibc version of
stdint.h. With edison and dora the #include_next will move to
the sysroot.
Is this a regression of gcc-4.9? is this a wanted change?
kind regards
holger
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: gcc 4.9.1 and stdint.h
2014-11-02 20:05 gcc 4.9.1 and stdint.h Holger Hans Peter Freyther
@ 2014-11-02 22:03 ` Richard Purdie
2014-11-03 7:22 ` Holger Hans Peter Freyther
0 siblings, 1 reply; 9+ messages in thread
From: Richard Purdie @ 2014-11-02 22:03 UTC (permalink / raw)
To: Holger Hans Peter Freyther; +Cc: poky
On Sun, 2014-11-02 at 21:05 +0100, Holger Hans Peter Freyther wrote:
> Hi,
>
> I have a small piece of initial bootloader and it fails to compile
> using master (f19b4e995ea47f9243f152b39337330307453c9f). The code
> does include "stdint.h" which ends up with a failure like this:
>
> tmp/sysroots/i686-linux/usr/lib/arm-poky-linux-gnueabi/gcc/arm-poky-linux-gnueabi/4.9.1/include/stdint.h:9:26: fatal error: stdint.h: No such file or directory
> | # include_next <stdint.h>
> | ^
> | compilation terminated.
>
>
> So somehow gcc doesn't know how to find the glibc version of
> stdint.h. With edison and dora the #include_next will move to
> the sysroot.
>
> Is this a regression of gcc-4.9? is this a wanted change?
What was the compiler commandline you used and did you specify the
sysroot? Was this was master or dizzy?
Cheers,
Richard
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: gcc 4.9.1 and stdint.h
2014-11-02 22:03 ` Richard Purdie
@ 2014-11-03 7:22 ` Holger Hans Peter Freyther
2014-11-03 8:04 ` Richard Purdie
0 siblings, 1 reply; 9+ messages in thread
From: Holger Hans Peter Freyther @ 2014-11-03 7:22 UTC (permalink / raw)
To: Richard Purdie; +Cc: poky
On Sun, Nov 02, 2014 at 10:03:35PM +0000, Richard Purdie wrote:
Good Morning,
> What was the compiler commandline you used and did you specify the
> sysroot? Was this was master or dizzy?
that was with master. The command line for the compilation is:
arm-poky-linux-gnueabi-gcc -c -Os -Wall -mabi=aapcs-linux -DDM644x -DFLASH_TYPE_NAND -Dboard_sysmobts_v2 -DENABLE_BOOT_INTERRUPT -c -o davinci.o davinci.c
Okay the Makefile didn't honor the CC variable from the environment.
How did that work before? Did gcc have a default sysroot?
holger
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: gcc 4.9.1 and stdint.h
2014-11-03 7:22 ` Holger Hans Peter Freyther
@ 2014-11-03 8:04 ` Richard Purdie
2014-11-03 15:12 ` Holger Hans Peter Freyther
0 siblings, 1 reply; 9+ messages in thread
From: Richard Purdie @ 2014-11-03 8:04 UTC (permalink / raw)
To: Holger Hans Peter Freyther; +Cc: poky
On Mon, 2014-11-03 at 08:22 +0100, Holger Hans Peter Freyther wrote:
> On Sun, Nov 02, 2014 at 10:03:35PM +0000, Richard Purdie wrote:
>
> Good Morning,
>
> > What was the compiler commandline you used and did you specify the
> > sysroot? Was this was master or dizzy?
>
> that was with master. The command line for the compilation is:
>
> arm-poky-linux-gnueabi-gcc -c -Os -Wall -mabi=aapcs-linux -DDM644x -DFLASH_TYPE_NAND -Dboard_sysmobts_v2 -DENABLE_BOOT_INTERRUPT -c -o davinci.o davinci.c
>
> Okay the Makefile didn't honor the CC variable from the environment.
> How did that work before? Did gcc have a default sysroot?
Yes.
http://git.yoctoproject.org/cgit.cgi/poky/commit/?id=678e8798ebe0f4fd1bd347db136f1499b8fe00c9
Cheers,
Richard
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: gcc 4.9.1 and stdint.h
2014-11-03 8:04 ` Richard Purdie
@ 2014-11-03 15:12 ` Holger Hans Peter Freyther
2014-11-03 15:37 ` Richard Purdie
0 siblings, 1 reply; 9+ messages in thread
From: Holger Hans Peter Freyther @ 2014-11-03 15:12 UTC (permalink / raw)
To: Richard Purdie; +Cc: poky
On Mon, Nov 03, 2014 at 08:04:59AM +0000, Richard Purdie wrote:
Dear Richard,
> http://git.yoctoproject.org/cgit.cgi/poky/commit/?id=678e8798ebe0f4fd1bd347db136f1499b8fe00c9
thanks a lot for explaining. I see how using the default sysroot
with external toolchains is going to cause issues. What is the
reasoning to have it for the canadian cross (hence meta-toolchain)?
E.g. when compiling U-Boot linking will fail when just passing
make CROSS_COMPILE=/opt/poky/1.7/.../arm-..- (not going through
the sourcing of the environment file) the linking wil fail due a
missing -lgcc but maybe I am doing something wrong as well.
/opt/poky/1.7/sysroots/i686-pokysdk-linux/usr/bin/arm-poky-linux-gnueabi/arm-poky-linux-gnueabi-ld.bfd -g -Ttext 0xc100000 -o examples/standalone/hello_world -e hello_world examples/standalone/hello_world.o examples/standalone/libstubs.o -L . -lgcc
/opt/poky/1.7/sysroots/i686-pokysdk-linux/usr/bin/arm-poky-linux-gnueabi/arm-poky-linux-gnueabi-ld.bfd: cannot find -lgcc
gpl-uboot/examples/standalone/Makefile:67: recipe for target 'examples/standalone/hello_world' failed
make[2]: *** [examples/standalone/hello_world] Error 1
holger
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: gcc 4.9.1 and stdint.h
2014-11-03 15:12 ` Holger Hans Peter Freyther
@ 2014-11-03 15:37 ` Richard Purdie
2014-11-07 16:58 ` Holger Hans Peter Freyther
0 siblings, 1 reply; 9+ messages in thread
From: Richard Purdie @ 2014-11-03 15:37 UTC (permalink / raw)
To: Holger Hans Peter Freyther; +Cc: poky
On Mon, 2014-11-03 at 16:12 +0100, Holger Hans Peter Freyther wrote:
> On Mon, Nov 03, 2014 at 08:04:59AM +0000, Richard Purdie wrote:
>
> Dear Richard,
>
> > http://git.yoctoproject.org/cgit.cgi/poky/commit/?id=678e8798ebe0f4fd1bd347db136f1499b8fe00c9
>
> thanks a lot for explaining. I see how using the default sysroot
> with external toolchains is going to cause issues. What is the
> reasoning to have it for the canadian cross (hence meta-toolchain)?
The reasoning is that we have one canadian-cross compiler targeting
multiple sysroots (one arm compiler targets all arm machines). The
compiled in sysroot may not be the final installation path anyway,
depending on where you install meta-toolchain.
We prefer deterministic builds rather than some toolchain installations
that work and some that don't.
Cheers,
Richard
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: gcc 4.9.1 and stdint.h
2014-11-03 15:37 ` Richard Purdie
@ 2014-11-07 16:58 ` Holger Hans Peter Freyther
2014-11-12 13:21 ` Richard Purdie
0 siblings, 1 reply; 9+ messages in thread
From: Holger Hans Peter Freyther @ 2014-11-07 16:58 UTC (permalink / raw)
To: Richard Purdie; +Cc: poky
On Mon, Nov 03, 2014 at 03:37:09PM +0000, Richard Purdie wrote:
> We prefer deterministic builds rather than some toolchain installations
> that work and some that don't.
Do you intend to create a script like the current environment that
could work with "bare" apps (like u-boot, linux kernel, initial
bootloaders, etc.)?
holger
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: gcc 4.9.1 and stdint.h
2014-11-07 16:58 ` Holger Hans Peter Freyther
@ 2014-11-12 13:21 ` Richard Purdie
2014-11-12 13:50 ` Holger Hans Peter Freyther
0 siblings, 1 reply; 9+ messages in thread
From: Richard Purdie @ 2014-11-12 13:21 UTC (permalink / raw)
To: Holger Hans Peter Freyther; +Cc: poky
On Fri, 2014-11-07 at 17:58 +0100, Holger Hans Peter Freyther wrote:
> On Mon, Nov 03, 2014 at 03:37:09PM +0000, Richard Purdie wrote:
>
> > We prefer deterministic builds rather than some toolchain installations
> > that work and some that don't.
>
> Do you intend to create a script like the current environment that
> could work with "bare" apps (like u-boot, linux kernel, initial
> bootloaders, etc.)?
I'd like to understand what differences such an environment script would
have but would be happy to consider it...
Cheers,
Richard
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: gcc 4.9.1 and stdint.h
2014-11-12 13:21 ` Richard Purdie
@ 2014-11-12 13:50 ` Holger Hans Peter Freyther
0 siblings, 0 replies; 9+ messages in thread
From: Holger Hans Peter Freyther @ 2014-11-12 13:50 UTC (permalink / raw)
To: Richard Purdie; +Cc: poky
On Wed, Nov 12, 2014 at 01:21:11PM +0000, Richard Purdie wrote:
> I'd like to understand what differences such an environment script would
> have but would be happy to consider it...
I am not sure. My question is how to compile a kernel with the
result of meta-toolchain? Until this commit setting CROSS_COMPILE=/opt/..-
was enough. But now my users probably need to pass CC and LD as
variables as well? The current environment file passes -Wl, to
the linker which doesn't work with the kernel compilation. So I
wondered if one could create a script with enough variables to
easily compile things like UBL, U-Boot, Linux?
^ permalink raw reply [flat|nested] 9+ messages in thread
end of thread, other threads:[~2014-11-12 13:51 UTC | newest]
Thread overview: 9+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-11-02 20:05 gcc 4.9.1 and stdint.h Holger Hans Peter Freyther
2014-11-02 22:03 ` Richard Purdie
2014-11-03 7:22 ` Holger Hans Peter Freyther
2014-11-03 8:04 ` Richard Purdie
2014-11-03 15:12 ` Holger Hans Peter Freyther
2014-11-03 15:37 ` Richard Purdie
2014-11-07 16:58 ` Holger Hans Peter Freyther
2014-11-12 13:21 ` Richard Purdie
2014-11-12 13:50 ` Holger Hans Peter Freyther
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.